highcharts-rails 6.0.2 → 6.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CCBYNC-LICENSE +103 -0
- data/CHANGELOG.markdown +31 -0
- data/Highsoft-LICENSE +1 -0
- data/{LICENSE → MIT-LICENSE} +0 -0
- data/README.markdown +6 -6
- data/app/assets/javascripts/highcharts.js +1635 -498
- data/app/assets/javascripts/highcharts/highcharts-3d.js +1 -1
- data/app/assets/javascripts/highcharts/highcharts-more.js +2 -2
- data/app/assets/javascripts/highcharts/modules/accessibility.js +1072 -824
- data/app/assets/javascripts/highcharts/modules/annotations.js +1 -1
- data/app/assets/javascripts/highcharts/modules/boost-canvas.js +3 -13
- data/app/assets/javascripts/highcharts/modules/boost.js +29 -13
- data/app/assets/javascripts/highcharts/modules/broken-axis.js +1 -1
- data/app/assets/javascripts/highcharts/modules/bullet.js +1 -1
- data/app/assets/javascripts/highcharts/modules/data.js +6 -6
- data/app/assets/javascripts/highcharts/modules/drag-panes.js +1 -1
- data/app/assets/javascripts/highcharts/modules/drilldown.js +1 -1
- data/app/assets/javascripts/highcharts/modules/export-data.js +10 -12
- data/app/assets/javascripts/highcharts/modules/exporting.js +1 -1
- data/app/assets/javascripts/highcharts/modules/funnel.js +1 -1
- data/app/assets/javascripts/highcharts/modules/gantt.js +26 -78
- data/app/assets/javascripts/highcharts/modules/grid-axis.js +1 -1
- data/app/assets/javascripts/highcharts/modules/heatmap.js +1 -1
- data/app/assets/javascripts/highcharts/modules/histogram-bellcurve.js +1 -1
- data/app/assets/javascripts/highcharts/modules/item-series.js +1 -1
- data/app/assets/javascripts/highcharts/modules/no-data-to-display.js +6 -15
- data/app/assets/javascripts/highcharts/modules/offline-exporting.js +2 -2
- data/app/assets/javascripts/highcharts/modules/oldie.js +2 -2
- data/app/assets/javascripts/highcharts/modules/overlapping-datalabels.js +41 -47
- data/app/assets/javascripts/highcharts/modules/parallel-coordinates.js +10 -6
- data/app/assets/javascripts/highcharts/modules/pareto.js +9 -1
- data/app/assets/javascripts/highcharts/modules/sankey.js +1 -1
- data/app/assets/javascripts/highcharts/modules/series-label.js +1 -1
- data/app/assets/javascripts/highcharts/modules/solid-gauge.js +1 -1
- data/app/assets/javascripts/highcharts/modules/static-scale.js +2 -6
- data/app/assets/javascripts/highcharts/modules/stock.js +96 -30
- data/app/assets/javascripts/highcharts/modules/streamgraph.js +1 -1
- data/app/assets/javascripts/highcharts/modules/sunburst.js +82 -50
- data/app/assets/javascripts/highcharts/modules/tilemap.js +1 -1
- data/app/assets/javascripts/highcharts/modules/treemap.js +10 -2
- data/app/assets/javascripts/highcharts/modules/variable-pie.js +1 -1
- data/app/assets/javascripts/highcharts/modules/variwide.js +1 -1
- data/app/assets/javascripts/highcharts/modules/vector.js +1 -1
- data/app/assets/javascripts/highcharts/modules/windbarb.js +1 -1
- data/app/assets/javascripts/highcharts/modules/wordcloud.js +7 -3
- data/app/assets/javascripts/highcharts/modules/xrange.js +24 -76
- data/app/assets/javascripts/highcharts/themes/avocado.js +1 -1
- data/app/assets/javascripts/highcharts/themes/dark-blue.js +1 -1
- data/app/assets/javascripts/highcharts/themes/dark-green.js +1 -1
- data/app/assets/javascripts/highcharts/themes/dark-unica.js +1 -1
- data/app/assets/javascripts/highcharts/themes/gray.js +1 -1
- data/app/assets/javascripts/highcharts/themes/grid-light.js +1 -1
- data/app/assets/javascripts/highcharts/themes/grid.js +1 -1
- data/app/assets/javascripts/highcharts/themes/sand-signika.js +1 -1
- data/app/assets/javascripts/highcharts/themes/skies.js +1 -1
- data/app/assets/javascripts/highcharts/themes/sunset.js +1 -1
- data/highcharts-rails.gemspec +1 -0
- data/lib/highcharts/version.rb +1 -1
- metadata +9 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e034cc6bfee99410456aaff4e694bd12ab1f582f
|
4
|
+
data.tar.gz: f5108ae98e259594cfb810ded1c034d3700c06f5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cfc2d2d6b273705b8ec7478f762dd2cec6e9fb3c3e774a1b5372c5c5fa1d1868c77ef9d4184670add5681f4cbd8af2e6f433abf1d2123fce30bed423c40c9588
|
7
|
+
data.tar.gz: 6c861bf70c1e7e9658072a59c5ad0cf3e50c160561d17243dbfb909e49980bb140b81cd2bffb036b5ed17c6e3835fc778bbeabdc1922e9b0e1737e75b479d77a
|
data/CCBYNC-LICENSE
ADDED
@@ -0,0 +1,103 @@
|
|
1
|
+
## creative commons
|
2
|
+
|
3
|
+
# Attribution-NonCommercial 3.0 Unported
|
4
|
+
|
5
|
+
CREATIVE COMMONS CORPORATION IS NOT A LAW FIRM AND DOES NOT PROVIDE LEGAL SERVICES. DISTRIBUTION OF THIS LICENSE DOES NOT CREATE AN ATTORNEY-CLIENT RELATIONSHIP. CREATIVE COMMONS PROVIDES THIS INFORMATION ON AN "AS-IS" BASIS. CREATIVE COMMONS MAKES NO WARRANTIES REGARDING THE INFORMATION PROVIDED, AND DISCLAIMS LIABILITY FOR DAMAGES RESULTING FROM ITS USE.
|
6
|
+
|
7
|
+
*License*
|
8
|
+
|
9
|
+
THE WORK (AS DEFINED BELOW) IS PROVIDED UNDER THE TERMS OF THIS CREATIVE COMMONS PUBLIC LICENSE ("CCPL" OR "LICENSE"). THE WORK IS PROTECTED BY COPYRIGHT AND/OR OTHER APPLICABLE LAW. ANY USE OF THE WORK OTHER THAN AS AUTHORIZED UNDER THIS LICENSE OR COPYRIGHT LAW IS PROHIBITED.
|
10
|
+
|
11
|
+
BY EXERCISING ANY RIGHTS TO THE WORK PROVIDED HERE, YOU ACCEPT AND AGREE TO BE BOUND BY THE TERMS OF THIS LICENSE. TO THE EXTENT THIS LICENSE MAY BE CONSIDERED TO BE A CONTRACT, THE LICENSOR GRANTS YOU THE RIGHTS CONTAINED HERE IN CONSIDERATION OF YOUR ACCEPTANCE OF SUCH TERMS AND CONDITIONS.
|
12
|
+
|
13
|
+
### 1. Definitions
|
14
|
+
|
15
|
+
a. __"Adaptation"__ means a work based upon the Work, or upon the Work and other pre-existing works, such as a translation, adaptation, derivative work, arrangement of music or other alterations of a literary or artistic work, or phonogram or performance and includes cinematographic adaptations or any other form in which the Work may be recast, transformed, or adapted including in any form recognizably derived from the original, except that a work that constitutes a Collection will not be considered an Adaptation for the purpose of this License. For the avoidance of doubt, where the Work is a musical work, performance or phonogram, the synchronization of the Work in timed-relation with a moving image ("synching") will be considered an Adaptation for the purpose of this License.
|
16
|
+
|
17
|
+
b. __"Collection"__ means a collection of literary or artistic works, such as encyclopedias and anthologies, or performances, phonograms or broadcasts, or other works or subject matter other than works listed in Section 1(f) below, which, by reason of the selection and arrangement of their contents, constitute intellectual creations, in which the Work is included in its entirety in unmodified form along with one or more other contributions, each constituting separate and independent works in themselves, which together are assembled into a collective whole. A work that constitutes a Collection will not be considered an Adaptation (as defined above) for the purposes of this License.
|
18
|
+
|
19
|
+
c. __"Distribute"__ means to make available to the public the original and copies of the Work or Adaptation, as appropriate, through sale or other transfer of ownership.
|
20
|
+
|
21
|
+
d. __"Licensor"__ means the individual, individuals, entity or entities that offer(s) the Work under the terms of this License.
|
22
|
+
|
23
|
+
e. __"Original Author"__ means, in the case of a literary or artistic work, the individual, individuals, entity or entities who created the Work or if no individual or entity can be identified, the publisher; and in addition (i) in the case of a performance the actors, singers, musicians, dancers, and other persons who act, sing, deliver, declaim, play in, interpret or otherwise perform literary or artistic works or expressions of folklore; (ii) in the case of a phonogram the producer being the person or legal entity who first fixes the sounds of a performance or other sounds; and, (iii) in the case of broadcasts, the organization that transmits the broadcast.
|
24
|
+
|
25
|
+
f. __"Work"__ means the literary and/or artistic work offered under the terms of this License including without limitation any production in the literary, scientific and artistic domain, whatever may be the mode or form of its expression including digital form, such as a book, pamphlet and other writing; a lecture, address, sermon or other work of the same nature; a dramatic or dramatico-musical work; a choreographic work or entertainment in dumb show; a musical composition with or without words; a cinematographic work to which are assimilated works expressed by a process analogous to cinematography; a work of drawing, painting, architecture, sculpture, engraving or lithography; a photographic work to which are assimilated works expressed by a process analogous to photography; a work of applied art; an illustration, map, plan, sketch or three-dimensional work relative to geography, topography, architecture or science; a performance; a broadcast; a phonogram; a compilation of data to the extent it is protected as a copyrightable work; or a work performed by a variety or circus performer to the extent it is not otherwise considered a literary or artistic work.
|
26
|
+
|
27
|
+
g. __"You"__ means an individual or entity exercising rights under this License who has not previously violated the terms of this License with respect to the Work, or who has received express permission from the Licensor to exercise rights under this License despite a previous violation.
|
28
|
+
|
29
|
+
h. __"Publicly Perform"__ means to perform public recitations of the Work and to communicate to the public those public recitations, by any means or process, including by wire or wireless means or public digital performances; to make available to the public Works in such a way that members of the public may access these Works from a place and at a place individually chosen by them; to perform the Work to the public by any means or process and the communication to the public of the performances of the Work, including by public digital performance; to broadcast and rebroadcast the Work by any means including signs, sounds or images.
|
30
|
+
|
31
|
+
i. __"Reproduce"__ means to make copies of the Work by any means including without limitation by sound or visual recordings and the right of fixation and reproducing fixations of the Work, including storage of a protected performance or phonogram in digital form or other electronic medium.
|
32
|
+
|
33
|
+
### 2. Fair Dealing Rights
|
34
|
+
|
35
|
+
Nothing in this License is intended to reduce, limit, or restrict any uses free from copyright or rights arising from limitations or exceptions that are provided for in connection with the copyright protection under copyright law or other applicable laws.
|
36
|
+
|
37
|
+
### 3. License Grant
|
38
|
+
|
39
|
+
Subject to the terms and conditions of this License, Licensor hereby grants You a worldwide, royalty-free, non-exclusive, perpetual (for the duration of the applicable copyright) license to exercise the rights in the Work as stated below:
|
40
|
+
|
41
|
+
a. to Reproduce the Work, to incorporate the Work into one or more Collections, and to Reproduce the Work as incorporated in the Collections;
|
42
|
+
|
43
|
+
b. to create and Reproduce Adaptations provided that any such Adaptation, including any translation in any medium, takes reasonable steps to clearly label, demarcate or otherwise identify that changes were made to the original Work. For example, a translation could be marked "The original work was translated from English to Spanish," or a modification could indicate "The original work has been modified.";
|
44
|
+
|
45
|
+
c. to Distribute and Publicly Perform the Work including as incorporated in Collections; and,
|
46
|
+
|
47
|
+
d. to Distribute and Publicly Perform Adaptations.
|
48
|
+
|
49
|
+
The above rights may be exercised in all media and formats whether now known or hereafter devised. The above rights include the right to make such modifications as are technically necessary to exercise the rights in other media and formats. Subject to Section 8(f), all rights not expressly granted by Licensor are hereby reserved, including but not limited to the rights set forth in Section 4(d).
|
50
|
+
|
51
|
+
### 4. Restrictions
|
52
|
+
|
53
|
+
The license granted in Section 3 above is expressly made subject to and limited by the following restrictions:
|
54
|
+
|
55
|
+
a. You may Distribute or Publicly Perform the Work only under the terms of this License. You must include a copy of, or the Uniform Resource Identifier (URI) for, this License with every copy of the Work You Distribute or Publicly Perform. You may not offer or impose any terms on the Work that restrict the terms of this License or the ability of the recipient of the Work to exercise the rights granted to that recipient under the terms of the License. You may not sublicense the Work. You must keep intact all notices that refer to this License and to the disclaimer of warranties with every copy of the Work You Distribute or Publicly Perform. When You Distribute or Publicly Perform the Work, You may not impose any effective technological measures on the Work that restrict the ability of a recipient of the Work from You to exercise the rights granted to that recipient under the terms of the License. This Section 4(a) applies to the Work as incorporated in a Collection, but this does not require the Collection apart from the Work itself to be made subject to the terms of this License. If You create a Collection, upon notice from any Licensor You must, to the extent practicable, remove from the Collection any credit as required by Section 4(c), as requested. If You create an Adaptation, upon notice from any Licensor You must, to the extent practicable, remove from the Adaptation any credit as required by Section 4(c), as requested.
|
56
|
+
|
57
|
+
b. You may not exercise any of the rights granted to You in Section 3 above in any manner that is primarily intended for or directed toward commercial advantage or private monetary compensation. The exchange of the Work for other copyrighted works by means of digital file-sharing or otherwise shall not be considered to be intended for or directed toward commercial advantage or private monetary compensation, provided there is no payment of any monetary compensation in connection with the exchange of copyrighted works.
|
58
|
+
|
59
|
+
c. If You Distribute, or Publicly Perform the Work or any Adaptations or Collections, You must, unless a request has been made pursuant to Section 4(a), keep intact all copyright notices for the Work and provide, reasonable to the medium or means You are utilizing: (i) the name of the Original Author (or pseudonym, if applicable) if supplied, and/or if the Original Author and/or Licensor designate another party or parties (e.g., a sponsor institute, publishing entity, journal) for attribution ("Attribution Parties") in Licensor's copyright notice, terms of service or by other reasonable means, the name of such party or parties; (ii) the title of the Work if supplied; (iii) to the extent reasonably practicable, the URI, if any, that Licensor specifies to be associated with the Work, unless such URI does not refer to the copyright notice or licensing information for the Work; and, (iv) consistent with Section 3(b), in the case of an Adaptation, a credit identifying the use of the Work in the Adaptation (e.g., "French translation of the Work by Original Author," or "Screenplay based on original Work by Original Author"). The credit required by this Section 4(c) may be implemented in any reasonable manner; provided, however, that in the case of a Adaptation or Collection, at a minimum such credit will appear, if a credit for all contributing authors of the Adaptation or Collection appears, then as part of these credits and in a manner at least as prominent as the credits for the other contributing authors. For the avoidance of doubt, You may only use the credit required by this Section for the purpose of attribution in the manner set out above and, by exercising Your rights under this License, You may not implicitly or explicitly assert or imply any connection with, sponsorship or endorsement by the Original Author, Licensor and/or Attribution Parties, as appropriate, of You or Your use of the Work, without the separate, express prior written permission of the Original Author, Licensor and/or Attribution Parties.
|
60
|
+
|
61
|
+
d. For the avoidance of doubt:
|
62
|
+
|
63
|
+
1. __Non-waivable Compulsory License Schemes.__ In those jurisdictions in which the right to collect royalties through any statutory or compulsory licensing scheme cannot be waived, the Licensor reserves the exclusive right to collect such royalties for any exercise by You of the rights granted under this License;
|
64
|
+
|
65
|
+
2. __Waivable Compulsory License Schemes.__ In those jurisdictions in which the right to collect royalties through any statutory or compulsory licensing scheme can be waived, the Licensor reserves the exclusive right to collect such royalties for any exercise by You of the rights granted under this License if Your exercise of such rights is for a purpose or use which is otherwise than noncommercial as permitted under Section 4(b) and otherwise waives the right to collect royalties through any statutory or compulsory licensing scheme; and,
|
66
|
+
|
67
|
+
3. __Voluntary License Schemes.__ The Licensor reserves the right to collect royalties, whether individually or, in the event that the Licensor is a member of a collecting society that administers voluntary licensing schemes, via that society, from any exercise by You of the rights granted under this License that is for a purpose or use which is otherwise than noncommercial as permitted under Section 4(c).
|
68
|
+
|
69
|
+
e. Except as otherwise agreed in writing by the Licensor or as may be otherwise permitted by applicable law, if You Reproduce, Distribute or Publicly Perform the Work either by itself or as part of any Adaptations or Collections, You must not distort, mutilate, modify or take other derogatory action in relation to the Work which would be prejudicial to the Original Author's honor or reputation. Licensor agrees that in those jurisdictions (e.g. Japan), in which any exercise of the right granted in Section 3(b) of this License (the right to make Adaptations) would be deemed to be a distortion, mutilation, modification or other derogatory action prejudicial to the Original Author's honor and reputation, the Licensor will waive or not assert, as appropriate, this Section, to the fullest extent permitted by the applicable national law, to enable You to reasonably exercise Your right under Section 3(b) of this License (right to make Adaptations) but not otherwise.
|
70
|
+
|
71
|
+
### 5. Representations, Warranties and Disclaimer
|
72
|
+
|
73
|
+
UNLESS OTHERWISE MUTUALLY AGREED TO BY THE PARTIES IN WRITING, LICENSOR OFFERS THE WORK AS-IS AND MAKES NO REPRESENTATIONS OR WARRANTIES OF ANY KIND CONCERNING THE WORK, EXPRESS, IMPLIED, STATUTORY OR OTHERWISE, INCLUDING, WITHOUT LIMITATION, WARRANTIES OF TITLE, MERCHANTIBILITY, FITNESS FOR A PARTICULAR PURPOSE, NONINFRINGEMENT, OR THE ABSENCE OF LATENT OR OTHER DEFECTS, ACCURACY, OR THE PRESENCE OF ABSENCE OF ERRORS, WHETHER OR NOT DISCOVERABLE. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OF IMPLIED WARRANTIES, SO SUCH EXCLUSION MAY NOT APPLY TO YOU.
|
74
|
+
|
75
|
+
### 6. Limitation on Liability
|
76
|
+
|
77
|
+
EXCEPT TO THE EXTENT REQUIRED BY APPLICABLE LAW, IN NO EVENT WILL LICENSOR BE LIABLE TO YOU ON ANY LEGAL THEORY FOR ANY SPECIAL, INCIDENTAL, CONSEQUENTIAL, PUNITIVE OR EXEMPLARY DAMAGES ARISING OUT OF THIS LICENSE OR THE USE OF THE WORK, EVEN IF LICENSOR HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
|
78
|
+
|
79
|
+
### 7. Termination
|
80
|
+
|
81
|
+
a. This License and the rights granted hereunder will terminate automatically upon any breach by You of the terms of this License. Individuals or entities who have received Adaptations or Collections from You under this License, however, will not have their licenses terminated provided such individuals or entities remain in full compliance with those licenses. Sections 1, 2, 5, 6, 7, and 8 will survive any termination of this License.
|
82
|
+
|
83
|
+
b. Subject to the above terms and conditions, the license granted here is perpetual (for the duration of the applicable copyright in the Work). Notwithstanding the above, Licensor reserves the right to release the Work under different license terms or to stop distributing the Work at any time; provided, however that any such election will not serve to withdraw this License (or any other license that has been, or is required to be, granted under the terms of this License), and this License will continue in full force and effect unless terminated as stated above.
|
84
|
+
|
85
|
+
### 8. Miscellaneous
|
86
|
+
|
87
|
+
a. Each time You Distribute or Publicly Perform the Work or a Collection, the Licensor offers to the recipient a license to the Work on the same terms and conditions as the license granted to You under this License.
|
88
|
+
|
89
|
+
b. Each time You Distribute or Publicly Perform an Adaptation, Licensor offers to the recipient a license to the original Work on the same terms and conditions as the license granted to You under this License.
|
90
|
+
|
91
|
+
c. If any provision of this License is invalid or unenforceable under applicable law, it shall not affect the validity or enforceability of the remainder of the terms of this License, and without further action by the parties to this agreement, such provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable.
|
92
|
+
|
93
|
+
d. No term or provision of this License shall be deemed waived and no breach consented to unless such waiver or consent shall be in writing and signed by the party to be charged with such waiver or consent.
|
94
|
+
|
95
|
+
e. This License constitutes the entire agreement between the parties with respect to the Work licensed here. There are no understandings, agreements or representations with respect to the Work not specified here. Licensor shall not be bound by any additional provisions that may appear in any communication from You. This License may not be modified without the mutual written agreement of the Licensor and You.
|
96
|
+
|
97
|
+
f. The rights granted under, and the subject matter referenced, in this License were drafted utilizing the terminology of the Berne Convention for the Protection of Literary and Artistic Works (as amended on September 28, 1979), the Rome Convention of 1961, the WIPO Copyright Treaty of 1996, the WIPO Performances and Phonograms Treaty of 1996 and the Universal Copyright Convention (as revised on July 24, 1971). These rights and subject matter take effect in the relevant jurisdiction in which the License terms are sought to be enforced according to the corresponding provisions of the implementation of those treaty provisions in the applicable national law. If the standard suite of rights granted under applicable copyright law includes additional rights not granted under this License, such additional rights are deemed to be included in the License; this License is not intended to restrict the license of any rights under applicable law.
|
98
|
+
|
99
|
+
> Creative Commons is not a party to this License, and makes no warranty whatsoever in connection with the Work. Creative Commons will not be liable to You or any party on any legal theory for any damages whatsoever, including without limitation any general, special, incidental or consequential damages arising in connection to this license. Notwithstanding the foregoing two (2) sentences, if Creative Commons has expressly identified itself as the Licensor hereunder, it shall have all rights and obligations of Licensor.
|
100
|
+
>
|
101
|
+
> Except for the limited purpose of indicating to the public that the Work is licensed under the CCPL, Creative Commons does not authorize the use by either party of the trademark "Creative Commons" or any related trademark or logo of Creative Commons without the prior written consent of Creative Commons. Any permitted use will be in compliance with Creative Commons' then-current trademark usage guidelines, as may be published on its website or otherwise made available upon request from time to time. For the avoidance of doubt, this trademark restriction does not form part of the License.
|
102
|
+
>
|
103
|
+
> Creative Commons may be contacted at https://creativecommons.org/.
|
data/CHANGELOG.markdown
CHANGED
@@ -1,3 +1,34 @@
|
|
1
|
+
# 6.0.3 / 2017-11-14
|
2
|
+
|
3
|
+
* Updated Highcharts to 6.0.3 (2017-11-14)
|
4
|
+
* Added new option, dataLabels.filter, for a declarative way of filtering data labels without using the formatter.
|
5
|
+
* Bug fixes
|
6
|
+
* Fixed #1841, bad animation when adding points in area ranges.
|
7
|
+
* Fixed #4994, improved documentation on loading Highcharts in ES6.
|
8
|
+
* Fixed #6183, small tick interval caused ticks to be merged to one.
|
9
|
+
* Fixed #6895, zoomed heat map wastn't clipped properly in boost mode.
|
10
|
+
* Fixed #6907, no focus indicator on some browsers.
|
11
|
+
* Fixed #7300, font-size in wordcloud was not set as pixels, causing Firefox to render all words equal size.
|
12
|
+
* Fixed #7311, minPointLength wasn't correct for some cases.
|
13
|
+
* Fixed #7315, marker was listed as a column series option.
|
14
|
+
* Fixed #7315, removed wrong docs for series.column.marker and for shadow in hover and select states in column.states.
|
15
|
+
* Fixed #7316, null text with useHTML was throwing an error on getBBox().
|
16
|
+
* Fixed #7320, a regression causing responsive options for axes and series not being unset.
|
17
|
+
* Fixed #7326, setData with equal data length caused badly drawn stacked area series with null points.
|
18
|
+
* Fixed #7332, X-range data labels were not hidden for off-screen elements.
|
19
|
+
* Fixed #7339, removed doubled axis ticks in case of too dense ticks.
|
20
|
+
* Fixed #7342, improved documentation for xAxis.
|
21
|
+
* Fixed #7351, dynamically added checkboxes didn't respect scrolling after update.
|
22
|
+
* Fixed #7357, a chart without a title threw an error when trying to export data.
|
23
|
+
* Fixed #7369, scatter chart with series containing points with null and negative X didn't render.
|
24
|
+
* Fixed #7371, sunburst chart failed in styled mode.
|
25
|
+
* Fixed #7377, approximation averages wasn't returning undefined values as it should.
|
26
|
+
* Fixed issue with date parsing error appearing when not necessary.
|
27
|
+
* Fixed issue with markup passing unfiltered into aria-label attributes, causing invalid SVG.
|
28
|
+
* Fixed jsdoc plugin. Load highcharts assembler from npm.
|
29
|
+
* Fixed keyboard navigation for maps and heatmaps.
|
30
|
+
* Fixed navigator update issue. See #5846.
|
31
|
+
|
1
32
|
# 6.0.2 / 2017-11-10
|
2
33
|
|
3
34
|
* Update Highcharts to 6.0.2 (2017-10-20)
|
data/Highsoft-LICENSE
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
See https://shop.highsoft.com/media/highsoft/Standard-License-Agreement-9.0.pdf for the current version
|
data/{LICENSE → MIT-LICENSE}
RENAMED
File without changes
|
data/README.markdown
CHANGED
@@ -57,10 +57,10 @@ The gem itself is released under the MIT license
|
|
57
57
|
|
58
58
|
## Signing
|
59
59
|
|
60
|
-
Release tags and all released gems (from 3.0.0 onwards) is signed using [rubygems-openpgp](https://www.rubygems-openpgp-ca.org/) using [my personal key](https://eastblue.org/blag/
|
60
|
+
Release tags and all released gems (from 3.0.0 onwards) is signed using [rubygems-openpgp](https://www.rubygems-openpgp-ca.org/) using [my personal key](https://eastblue.org/blag/2013/gpg.html), and the fingerprint is also included below.
|
61
61
|
|
62
|
-
pub 4096R/
|
63
|
-
Key fingerprint =
|
64
|
-
uid
|
65
|
-
uid
|
66
|
-
sub 4096R/
|
62
|
+
pub 4096R/C9A283C9 2017-11-10 [expires: 2021-11-10]
|
63
|
+
Key fingerprint = 18C6 2780 9B69 5EAC 0183 69B1 DD27 0F98 C9A2 83C9
|
64
|
+
uid Per Christian Bechström Viken <perchr@northblue.org>
|
65
|
+
uid [jpeg image of size 9212]
|
66
|
+
sub 4096R/AFA535FE 2017-11-10 [expires: 2021-11-10]
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/**
|
2
|
-
* @license Highcharts JS v6.0.
|
2
|
+
* @license Highcharts JS v6.0.3 (2017-11-14)
|
3
3
|
*
|
4
4
|
* (c) 2009-2016 Torstein Honsi
|
5
5
|
*
|
@@ -21,18 +21,21 @@
|
|
21
21
|
*
|
22
22
|
* License: www.highcharts.com/license
|
23
23
|
*/
|
24
|
-
/* global win */
|
25
|
-
|
24
|
+
/* global win, window */
|
25
|
+
|
26
|
+
// glob is a temporary fix to allow our es-modules to work.
|
27
|
+
var glob = typeof win === 'undefined' ? window : win,
|
28
|
+
doc = glob.document,
|
26
29
|
SVG_NS = 'http://www.w3.org/2000/svg',
|
27
|
-
userAgent = (
|
30
|
+
userAgent = (glob.navigator && glob.navigator.userAgent) || '',
|
28
31
|
svg = doc && doc.createElementNS && !!doc.createElementNS(SVG_NS, 'svg').createSVGRect,
|
29
|
-
isMS = /(edge|msie|trident)/i.test(userAgent) && !
|
32
|
+
isMS = /(edge|msie|trident)/i.test(userAgent) && !glob.opera,
|
30
33
|
isFirefox = /Firefox/.test(userAgent),
|
31
|
-
hasBidiBug = isFirefox && parseInt(userAgent.split('Firefox/')[1], 10) < 4; // issue #38
|
34
|
+
hasBidiBug = isFirefox && parseInt(userAgent.split('Firefox/')[1], 10) < 4; // issue #38;
|
32
35
|
|
33
|
-
var Highcharts =
|
36
|
+
var Highcharts = glob.Highcharts ? glob.Highcharts.error(16, true) : {
|
34
37
|
product: 'Highcharts',
|
35
|
-
version: '6.0.
|
38
|
+
version: '6.0.3',
|
36
39
|
deg2rad: Math.PI * 2 / 360,
|
37
40
|
doc: doc,
|
38
41
|
hasBidiBug: hasBidiBug,
|
@@ -46,7 +49,7 @@
|
|
46
49
|
seriesTypes: {},
|
47
50
|
symbolSizes: {},
|
48
51
|
svg: svg,
|
49
|
-
win:
|
52
|
+
win: glob,
|
50
53
|
marginNames: ['plotTop', 'marginRight', 'marginBottom', 'plotLeft'],
|
51
54
|
noop: function() {
|
52
55
|
return undefined;
|
@@ -161,7 +164,7 @@
|
|
161
164
|
startVal = parseFloat(start[i]);
|
162
165
|
ret[i] =
|
163
166
|
isNaN(startVal) ? // a letter instruction like M or L
|
164
|
-
|
167
|
+
end[i] :
|
165
168
|
now * (parseFloat(end[i] - startVal)) + startVal;
|
166
169
|
|
167
170
|
}
|
@@ -1793,9 +1796,23 @@
|
|
1793
1796
|
*/
|
1794
1797
|
H.addEvent = function(el, type, fn) {
|
1795
1798
|
|
1796
|
-
var events
|
1799
|
+
var events,
|
1800
|
+
itemEvents,
|
1797
1801
|
addEventListener = el.addEventListener || H.addEventListenerPolyfill;
|
1798
1802
|
|
1803
|
+
// If events are previously set directly on the prototype, pick them up
|
1804
|
+
// and copy them over to the instance. Otherwise instance handlers would
|
1805
|
+
// be set on the prototype and apply to multiple charts in the page.
|
1806
|
+
if (el.hcEvents && !el.hasOwnProperty('hcEvents')) {
|
1807
|
+
itemEvents = {};
|
1808
|
+
H.objectEach(el.hcEvents, function(handlers, eventType) {
|
1809
|
+
itemEvents[eventType] = handlers.slice(0);
|
1810
|
+
});
|
1811
|
+
el.hcEvents = itemEvents;
|
1812
|
+
}
|
1813
|
+
|
1814
|
+
events = el.hcEvents = el.hcEvents || {};
|
1815
|
+
|
1799
1816
|
// Handle DOM events
|
1800
1817
|
if (addEventListener) {
|
1801
1818
|
addEventListener.call(el, type, fn, false);
|
@@ -2900,7 +2917,7 @@
|
|
2900
2917
|
// setter
|
2901
2918
|
} else {
|
2902
2919
|
|
2903
|
-
objectEach(hash, function(val, key) {
|
2920
|
+
objectEach(hash, function eachAttribute(val, key) {
|
2904
2921
|
skipAttr = false;
|
2905
2922
|
|
2906
2923
|
// Unless .attr is from the animator update, stop current
|
@@ -3572,7 +3589,8 @@
|
|
3572
3589
|
fontSize = styles && styles.fontSize;
|
3573
3590
|
|
3574
3591
|
|
3575
|
-
|
3592
|
+
// Avoid undefined and null (#7316)
|
3593
|
+
if (defined(textStr)) {
|
3576
3594
|
|
3577
3595
|
cacheKey = textStr.toString();
|
3578
3596
|
|
@@ -4333,6 +4351,10 @@
|
|
4333
4351
|
element = boxWrapper.element;
|
4334
4352
|
container.appendChild(element);
|
4335
4353
|
|
4354
|
+
// Always use ltr on the container, otherwise text-anchor will be
|
4355
|
+
// flipped and text appear outside labels, buttons, tooltip etc (#3482)
|
4356
|
+
attr(container, 'dir', 'ltr');
|
4357
|
+
|
4336
4358
|
// For browsers other than IE, add the namespace attribute (#1978)
|
4337
4359
|
if (container.innerHTML.indexOf('xmlns') === -1) {
|
4338
4360
|
attr(element, 'xmlns', this.SVG_NS);
|
@@ -4379,7 +4401,7 @@
|
|
4379
4401
|
// Add description
|
4380
4402
|
desc = this.createElement('desc').add();
|
4381
4403
|
desc.element.appendChild(
|
4382
|
-
doc.createTextNode('Created with Highcharts 6.0.
|
4404
|
+
doc.createTextNode('Created with Highcharts 6.0.3')
|
4383
4405
|
);
|
4384
4406
|
|
4385
4407
|
/**
|
@@ -6484,6 +6506,7 @@
|
|
6484
6506
|
isFirefox = H.isFirefox,
|
6485
6507
|
isMS = H.isMS,
|
6486
6508
|
isWebKit = H.isWebKit,
|
6509
|
+
pick = H.pick,
|
6487
6510
|
pInt = H.pInt,
|
6488
6511
|
SVGElement = H.SVGElement,
|
6489
6512
|
SVGRenderer = H.SVGRenderer,
|
@@ -6735,7 +6758,8 @@
|
|
6735
6758
|
if (value !== element.innerHTML) {
|
6736
6759
|
delete this.bBox;
|
6737
6760
|
}
|
6738
|
-
|
6761
|
+
this.textStr = value;
|
6762
|
+
element.innerHTML = pick(value, '');
|
6739
6763
|
wrapper.htmlUpdateTransform();
|
6740
6764
|
};
|
6741
6765
|
|
@@ -8241,11 +8265,9 @@
|
|
8241
8265
|
*
|
8242
8266
|
* @type {CSSObject}
|
8243
8267
|
* @sample {highcharts} highcharts/title/style/ Custom color and weight
|
8244
|
-
* @sample {highcharts} highcharts/css/titles/ Styled mode
|
8245
8268
|
* @sample {highstock} stock/chart/title-style/ Custom color and weight
|
8246
|
-
* @sample
|
8247
|
-
* @
|
8248
|
-
* @default {highcharts,highmaps} { "color": "#333333", "fontSize": "18px" }
|
8269
|
+
* @sample highcharts/css/titles/ Styled mode
|
8270
|
+
* @default {highcharts|highmaps} { "color": "#333333", "fontSize": "18px" }
|
8249
8271
|
* @default {highstock} { "color": "#333333", "fontSize": "16px" }
|
8250
8272
|
* @apioption title.style
|
8251
8273
|
*/
|
@@ -10602,10 +10624,257 @@
|
|
10602
10624
|
* @optionparent xAxis
|
10603
10625
|
*/
|
10604
10626
|
defaultOptions: {
|
10627
|
+
/**
|
10628
|
+
* Whether to allow decimals in this axis' ticks. When counting
|
10629
|
+
* integers, like persons or hits on a web page, decimals should
|
10630
|
+
* be avoided in the labels.
|
10631
|
+
*
|
10632
|
+
* @type {Boolean}
|
10633
|
+
* @see [minTickInterval](#xAxis.minTickInterval)
|
10634
|
+
* @sample {highcharts|highstock}
|
10635
|
+
* highcharts/yaxis/allowdecimals-true/
|
10636
|
+
* True by default
|
10637
|
+
* @sample {highcharts|highstock}
|
10638
|
+
* highcharts/yaxis/allowdecimals-false/
|
10639
|
+
* False
|
10640
|
+
* @default true
|
10641
|
+
* @since 2.0
|
10642
|
+
* @apioption xAxis.allowDecimals
|
10643
|
+
*/
|
10605
10644
|
// allowDecimals: null,
|
10645
|
+
|
10646
|
+
|
10647
|
+
/**
|
10648
|
+
* When using an alternate grid color, a band is painted across the
|
10649
|
+
* plot area between every other grid line.
|
10650
|
+
*
|
10651
|
+
* @type {Color}
|
10652
|
+
* @sample {highcharts} highcharts/yaxis/alternategridcolor/
|
10653
|
+
* Alternate grid color on the Y axis
|
10654
|
+
* @sample {highstock} stock/xaxis/alternategridcolor/
|
10655
|
+
* Alternate grid color on the Y axis
|
10656
|
+
* @default null
|
10657
|
+
* @apioption xAxis.alternateGridColor
|
10658
|
+
*/
|
10606
10659
|
// alternateGridColor: null,
|
10660
|
+
|
10661
|
+
/**
|
10662
|
+
* An array defining breaks in the axis, the sections defined will be
|
10663
|
+
* left out and all the points shifted closer to each other.
|
10664
|
+
*
|
10665
|
+
* @productdesc {highcharts}
|
10666
|
+
* Requires that the broken-axis.js module is loaded.
|
10667
|
+
*
|
10668
|
+
* @type {Array}
|
10669
|
+
* @sample {highcharts}
|
10670
|
+
* highcharts/axisbreak/break-simple/
|
10671
|
+
* Simple break
|
10672
|
+
* @sample {highcharts|highstock}
|
10673
|
+
* highcharts/axisbreak/break-visualized/
|
10674
|
+
* Advanced with callback
|
10675
|
+
* @sample {highstock}
|
10676
|
+
* stock/demo/intraday-breaks/
|
10677
|
+
* Break on nights and weekends
|
10678
|
+
* @since 4.1.0
|
10679
|
+
* @product highcharts highstock
|
10680
|
+
* @apioption xAxis.breaks
|
10681
|
+
*/
|
10682
|
+
|
10683
|
+
/**
|
10684
|
+
* A number indicating how much space should be left between the start
|
10685
|
+
* and the end of the break. The break size is given in axis units,
|
10686
|
+
* so for instance on a `datetime` axis, a break size of 3600000 would
|
10687
|
+
* indicate the equivalent of an hour.
|
10688
|
+
*
|
10689
|
+
* @type {Number}
|
10690
|
+
* @default 0
|
10691
|
+
* @since 4.1.0
|
10692
|
+
* @product highcharts highstock
|
10693
|
+
* @apioption xAxis.breaks.breakSize
|
10694
|
+
*/
|
10695
|
+
|
10696
|
+
/**
|
10697
|
+
* The point where the break starts.
|
10698
|
+
*
|
10699
|
+
* @type {Number}
|
10700
|
+
* @since 4.1.0
|
10701
|
+
* @product highcharts highstock
|
10702
|
+
* @apioption xAxis.breaks.from
|
10703
|
+
*/
|
10704
|
+
|
10705
|
+
/**
|
10706
|
+
* Defines an interval after which the break appears again. By default
|
10707
|
+
* the breaks do not repeat.
|
10708
|
+
*
|
10709
|
+
* @type {Number}
|
10710
|
+
* @default 0
|
10711
|
+
* @since 4.1.0
|
10712
|
+
* @product highcharts highstock
|
10713
|
+
* @apioption xAxis.breaks.repeat
|
10714
|
+
*/
|
10715
|
+
|
10716
|
+
/**
|
10717
|
+
* The point where the break ends.
|
10718
|
+
*
|
10719
|
+
* @type {Number}
|
10720
|
+
* @since 4.1.0
|
10721
|
+
* @product highcharts highstock
|
10722
|
+
* @apioption xAxis.breaks.to
|
10723
|
+
*/
|
10724
|
+
|
10725
|
+
/**
|
10726
|
+
* If categories are present for the xAxis, names are used instead of
|
10727
|
+
* numbers for that axis. Since Highcharts 3.0, categories can also
|
10728
|
+
* be extracted by giving each point a [name](#series.data) and setting
|
10729
|
+
* axis [type](#xAxis.type) to `category`. However, if you have multiple
|
10730
|
+
* series, best practice remains defining the `categories` array.
|
10731
|
+
*
|
10732
|
+
* Example:
|
10733
|
+
*
|
10734
|
+
* <pre>categories: ['Apples', 'Bananas', 'Oranges']</pre>
|
10735
|
+
*
|
10736
|
+
* @type {Array<String>}
|
10737
|
+
* @sample {highcharts} highcharts/chart/reflow-true/
|
10738
|
+
* With
|
10739
|
+
* @sample {highcharts} highcharts/xaxis/categories/
|
10740
|
+
* Without
|
10741
|
+
* @product highcharts
|
10742
|
+
* @default null
|
10743
|
+
* @apioption xAxis.categories
|
10744
|
+
*/
|
10607
10745
|
// categories: [],
|
10608
10746
|
|
10747
|
+
/**
|
10748
|
+
* The highest allowed value for automatically computed axis extremes.
|
10749
|
+
*
|
10750
|
+
* @type {Number}
|
10751
|
+
* @see [floor](#xAxis.floor)
|
10752
|
+
* @sample {highcharts|highstock} highcharts/yaxis/floor-ceiling/
|
10753
|
+
* Floor and ceiling
|
10754
|
+
* @since 4.0
|
10755
|
+
* @product highcharts highstock
|
10756
|
+
* @apioption xAxis.ceiling
|
10757
|
+
*/
|
10758
|
+
|
10759
|
+
/**
|
10760
|
+
* A class name that opens for styling the axis by CSS, especially in
|
10761
|
+
* Highcharts styled mode. The class name is applied to group elements
|
10762
|
+
* for the grid, axis elements and labels.
|
10763
|
+
*
|
10764
|
+
* @type {String}
|
10765
|
+
* @sample {highcharts|highstock|highmaps}
|
10766
|
+
* highcharts/css/axis/
|
10767
|
+
* Multiple axes with separate styling
|
10768
|
+
* @since 5.0.0
|
10769
|
+
* @apioption xAxis.className
|
10770
|
+
*/
|
10771
|
+
|
10772
|
+
/**
|
10773
|
+
* Configure a crosshair that follows either the mouse pointer or the
|
10774
|
+
* hovered point.
|
10775
|
+
*
|
10776
|
+
* In styled mode, the crosshairs are styled in the
|
10777
|
+
* `.highcharts-crosshair`, `.highcharts-crosshair-thin` or
|
10778
|
+
* `.highcharts-xaxis-category` classes.
|
10779
|
+
*
|
10780
|
+
* @productdesc {highstock}
|
10781
|
+
* In Highstock, bu default, the crosshair is enabled on the X axis and
|
10782
|
+
* disabled on the Y axis.
|
10783
|
+
*
|
10784
|
+
* @type {Boolean|Object}
|
10785
|
+
* @sample {highcharts} highcharts/xaxis/crosshair-both/
|
10786
|
+
* Crosshair on both axes
|
10787
|
+
* @sample {highstock} stock/xaxis/crosshairs-xy/
|
10788
|
+
* Crosshair on both axes
|
10789
|
+
* @sample {highmaps} highcharts/xaxis/crosshair-both/
|
10790
|
+
* Crosshair on both axes
|
10791
|
+
* @default false
|
10792
|
+
* @since 4.1
|
10793
|
+
* @apioption xAxis.crosshair
|
10794
|
+
*/
|
10795
|
+
|
10796
|
+
/**
|
10797
|
+
* A class name for the crosshair, especially as a hook for styling.
|
10798
|
+
*
|
10799
|
+
* @type {String}
|
10800
|
+
* @since 5.0.0
|
10801
|
+
* @apioption xAxis.crosshair.className
|
10802
|
+
*/
|
10803
|
+
|
10804
|
+
/**
|
10805
|
+
* The color of the crosshair. Defaults to `#cccccc` for numeric and
|
10806
|
+
* datetime axes, and `rgba(204,214,235,0.25)` for category axes, where
|
10807
|
+
* the crosshair by default highlights the whole category.
|
10808
|
+
*
|
10809
|
+
* @type {Color}
|
10810
|
+
* @sample {highcharts|highstock|highmaps}
|
10811
|
+
* highcharts/xaxis/crosshair-customized/
|
10812
|
+
* Customized crosshairs
|
10813
|
+
* @default #cccccc
|
10814
|
+
* @since 4.1
|
10815
|
+
* @apioption xAxis.crosshair.color
|
10816
|
+
*/
|
10817
|
+
|
10818
|
+
/**
|
10819
|
+
* The dash style for the crosshair. See
|
10820
|
+
* [series.dashStyle](#plotOptions.series.dashStyle)
|
10821
|
+
* for possible values.
|
10822
|
+
*
|
10823
|
+
* @validvalue ["Solid", "ShortDash", "ShortDot", "ShortDashDot",
|
10824
|
+
* "ShortDashDotDot", "Dot", "Dash" ,"LongDash",
|
10825
|
+
* "DashDot", "LongDashDot", "LongDashDotDot"]
|
10826
|
+
* @type {String}
|
10827
|
+
* @sample {highcharts|highmaps} highcharts/xaxis/crosshair-dotted/
|
10828
|
+
* Dotted crosshair
|
10829
|
+
* @sample {highstock} stock/xaxis/crosshair-dashed/
|
10830
|
+
* Dashed X axis crosshair
|
10831
|
+
* @default Solid
|
10832
|
+
* @since 4.1
|
10833
|
+
* @apioption xAxis.crosshair.dashStyle
|
10834
|
+
*/
|
10835
|
+
|
10836
|
+
/**
|
10837
|
+
* Whether the crosshair should snap to the point or follow the pointer
|
10838
|
+
* independent of points.
|
10839
|
+
*
|
10840
|
+
* @type {Boolean}
|
10841
|
+
* @sample {highcharts|highstock}
|
10842
|
+
* highcharts/xaxis/crosshair-snap-false/
|
10843
|
+
* True by default
|
10844
|
+
* @sample {highmaps}
|
10845
|
+
* maps/demo/latlon-advanced/
|
10846
|
+
* Snap is false
|
10847
|
+
* @default true
|
10848
|
+
* @since 4.1
|
10849
|
+
* @apioption xAxis.crosshair.snap
|
10850
|
+
*/
|
10851
|
+
|
10852
|
+
/**
|
10853
|
+
* The pixel width of the crosshair. Defaults to 1 for numeric or
|
10854
|
+
* datetime axes, and for one category width for category axes.
|
10855
|
+
*
|
10856
|
+
* @type {Number}
|
10857
|
+
* @sample {highcharts} highcharts/xaxis/crosshair-customized/
|
10858
|
+
* Customized crosshairs
|
10859
|
+
* @sample {highstock} highcharts/xaxis/crosshair-customized/
|
10860
|
+
* Customized crosshairs
|
10861
|
+
* @sample {highmaps} highcharts/xaxis/crosshair-customized/
|
10862
|
+
* Customized crosshairs
|
10863
|
+
* @default 1
|
10864
|
+
* @since 4.1
|
10865
|
+
* @apioption xAxis.crosshair.width
|
10866
|
+
*/
|
10867
|
+
|
10868
|
+
/**
|
10869
|
+
* The Z index of the crosshair. Higher Z indices allow drawing the
|
10870
|
+
* crosshair on top of the series or behind the grid lines.
|
10871
|
+
*
|
10872
|
+
* @type {Number}
|
10873
|
+
* @default 2
|
10874
|
+
* @since 4.1
|
10875
|
+
* @apioption xAxis.crosshair.zIndex
|
10876
|
+
*/
|
10877
|
+
|
10609
10878
|
/**
|
10610
10879
|
* For a datetime axis, the scale will automatically adjust to the
|
10611
10880
|
* appropriate unit. This member gives the default string
|
@@ -10626,11 +10895,11 @@
|
|
10626
10895
|
* year: '%Y'
|
10627
10896
|
* }</pre>
|
10628
10897
|
*
|
10629
|
-
* @type
|
10630
|
-
* @sample
|
10631
|
-
*
|
10632
|
-
* @sample
|
10633
|
-
*
|
10898
|
+
* @type {Object}
|
10899
|
+
* @sample {highcharts} highcharts/xaxis/datetimelabelformats/
|
10900
|
+
* Different day format on X axis
|
10901
|
+
* @sample {highstock} stock/xaxis/datetimelabelformats/
|
10902
|
+
* More information in x axis labels
|
10634
10903
|
* @product highcharts highstock
|
10635
10904
|
*/
|
10636
10905
|
dateTimeLabelFormats: {
|
@@ -10644,21 +10913,176 @@
|
|
10644
10913
|
year: '%Y'
|
10645
10914
|
},
|
10646
10915
|
|
10916
|
+
/**
|
10917
|
+
* _Requires Accessibility module_
|
10918
|
+
*
|
10919
|
+
* Description of the axis to screen reader users.
|
10920
|
+
*
|
10921
|
+
* @type {String}
|
10922
|
+
* @default undefined
|
10923
|
+
* @since 5.0.0
|
10924
|
+
* @apioption xAxis.description
|
10925
|
+
*/
|
10926
|
+
|
10647
10927
|
/**
|
10648
10928
|
* Whether to force the axis to end on a tick. Use this option with
|
10649
10929
|
* the `maxPadding` option to control the axis end.
|
10930
|
+
*
|
10931
|
+
* @productdesc {highstock}
|
10932
|
+
* In Highstock, `endOnTick` is always false when the navigator is
|
10933
|
+
* enabled, to prevent jumpy scrolling.
|
10650
10934
|
*
|
10651
|
-
* @
|
10652
|
-
*
|
10653
|
-
* @sample {highcharts} highcharts/yaxis/endontick/
|
10654
|
-
*
|
10655
|
-
* @sample {highstock} stock/
|
10656
|
-
*
|
10657
|
-
* @
|
10935
|
+
* @sample {highcharts} highcharts/chart/reflow-true/
|
10936
|
+
* True by default
|
10937
|
+
* @sample {highcharts} highcharts/yaxis/endontick/
|
10938
|
+
* False
|
10939
|
+
* @sample {highstock} stock/demo/basic-line/
|
10940
|
+
* True by default
|
10941
|
+
* @sample {highstock} stock/xaxis/endontick/
|
10942
|
+
* False
|
10943
|
+
* @since 1.2.0
|
10658
10944
|
*/
|
10659
10945
|
endOnTick: false,
|
10660
|
-
// reversed: false,
|
10661
10946
|
|
10947
|
+
/**
|
10948
|
+
* Event handlers for the axis.
|
10949
|
+
*
|
10950
|
+
* @apioption xAxis.events
|
10951
|
+
*/
|
10952
|
+
|
10953
|
+
/**
|
10954
|
+
* An event fired after the breaks have rendered.
|
10955
|
+
*
|
10956
|
+
* @type {Function}
|
10957
|
+
* @see [breaks](#xAxis.breaks)
|
10958
|
+
* @sample {highcharts} highcharts/axisbreak/break-event/
|
10959
|
+
* AfterBreak Event
|
10960
|
+
* @since 4.1.0
|
10961
|
+
* @product highcharts
|
10962
|
+
* @apioption xAxis.events.afterBreaks
|
10963
|
+
*/
|
10964
|
+
|
10965
|
+
/**
|
10966
|
+
* As opposed to the `setExtremes` event, this event fires after the
|
10967
|
+
* final min and max values are computed and corrected for `minRange`.
|
10968
|
+
*
|
10969
|
+
*
|
10970
|
+
* Fires when the minimum and maximum is set for the axis, either by
|
10971
|
+
* calling the `.setExtremes()` method or by selecting an area in the
|
10972
|
+
* chart. One parameter, `event`, is passed to the function, containing
|
10973
|
+
* common event information.
|
10974
|
+
*
|
10975
|
+
* The new user set minimum and maximum values can be found by `event.
|
10976
|
+
* min` and `event.max`. These reflect the axis minimum and maximum
|
10977
|
+
* in axis values. The actual data extremes are found in `event.dataMin`
|
10978
|
+
* and `event.dataMax`.
|
10979
|
+
*
|
10980
|
+
* @type {Function}
|
10981
|
+
* @context Axis
|
10982
|
+
* @since 2.3
|
10983
|
+
* @apioption xAxis.events.afterSetExtremes
|
10984
|
+
*/
|
10985
|
+
|
10986
|
+
/**
|
10987
|
+
* An event fired when a break from this axis occurs on a point.
|
10988
|
+
*
|
10989
|
+
* @type {Function}
|
10990
|
+
* @see [breaks](#xAxis.breaks)
|
10991
|
+
* @context Axis
|
10992
|
+
* @sample {highcharts} highcharts/axisbreak/break-visualized/
|
10993
|
+
* Visualization of a Break
|
10994
|
+
* @since 4.1.0
|
10995
|
+
* @product highcharts
|
10996
|
+
* @apioption xAxis.events.pointBreak
|
10997
|
+
*/
|
10998
|
+
|
10999
|
+
/**
|
11000
|
+
* An event fired when a point falls inside a break from this axis.
|
11001
|
+
*
|
11002
|
+
* @type {Function}
|
11003
|
+
* @context Axis
|
11004
|
+
* @product highcharts highstock
|
11005
|
+
* @apioption xAxis.events.pointInBreak
|
11006
|
+
*/
|
11007
|
+
|
11008
|
+
/**
|
11009
|
+
* Fires when the minimum and maximum is set for the axis, either by
|
11010
|
+
* calling the `.setExtremes()` method or by selecting an area in the
|
11011
|
+
* chart. One parameter, `event`, is passed to the function,
|
11012
|
+
* containing common event information.
|
11013
|
+
*
|
11014
|
+
* The new user set minimum and maximum values can be found by `event.
|
11015
|
+
* min` and `event.max`. These reflect the axis minimum and maximum
|
11016
|
+
* in data values. When an axis is zoomed all the way out from the
|
11017
|
+
* "Reset zoom" button, `event.min` and `event.max` are null, and
|
11018
|
+
* the new extremes are set based on `this.dataMin` and `this.dataMax`.
|
11019
|
+
*
|
11020
|
+
* @type {Function}
|
11021
|
+
* @context Axis
|
11022
|
+
* @sample {highstock} stock/xaxis/events-setextremes/
|
11023
|
+
* Log new extremes on x axis
|
11024
|
+
* @since 1.2.0
|
11025
|
+
* @apioption xAxis.events.setExtremes
|
11026
|
+
*/
|
11027
|
+
|
11028
|
+
/**
|
11029
|
+
* The lowest allowed value for automatically computed axis extremes.
|
11030
|
+
*
|
11031
|
+
* @type {Number}
|
11032
|
+
* @see [ceiling](#yAxis.ceiling)
|
11033
|
+
* @sample {highcharts} highcharts/yaxis/floor-ceiling/
|
11034
|
+
* Floor and ceiling
|
11035
|
+
* @sample {highstock} stock/demo/lazy-loading/
|
11036
|
+
* Prevent negative stock price on Y axis
|
11037
|
+
* @default null
|
11038
|
+
* @since 4.0
|
11039
|
+
* @product highcharts highstock
|
11040
|
+
* @apioption xAxis.floor
|
11041
|
+
*/
|
11042
|
+
|
11043
|
+
/**
|
11044
|
+
* The dash or dot style of the grid lines. For possible values, see
|
11045
|
+
* [this demonstration](http://jsfiddle.net/gh/get/library/pure/
|
11046
|
+
*highcharts/highcharts/tree/master/samples/highcharts/plotoptions/
|
11047
|
+
*series-dashstyle-all/).
|
11048
|
+
*
|
11049
|
+
* @validvalue ["Solid", "ShortDash", "ShortDot", "ShortDashDot",
|
11050
|
+
* "ShortDashDotDot", "Dot", "Dash" ,"LongDash",
|
11051
|
+
* "DashDot", "LongDashDot", "LongDashDotDot"]
|
11052
|
+
* @type {String}
|
11053
|
+
* @sample {highcharts} highcharts/yaxis/gridlinedashstyle/
|
11054
|
+
* Long dashes
|
11055
|
+
* @sample {highstock} stock/xaxis/gridlinedashstyle/
|
11056
|
+
* Long dashes
|
11057
|
+
* @default Solid
|
11058
|
+
* @since 1.2
|
11059
|
+
* @apioption xAxis.gridLineDashStyle
|
11060
|
+
*/
|
11061
|
+
|
11062
|
+
/**
|
11063
|
+
* The Z index of the grid lines.
|
11064
|
+
*
|
11065
|
+
* @type {Number}
|
11066
|
+
* @sample {highcharts|highstock} highcharts/xaxis/gridzindex/
|
11067
|
+
* A Z index of 4 renders the grid above the graph
|
11068
|
+
* @default 1
|
11069
|
+
* @product highcharts highstock
|
11070
|
+
* @apioption xAxis.gridZIndex
|
11071
|
+
*/
|
11072
|
+
|
11073
|
+
/**
|
11074
|
+
* An id for the axis. This can be used after render time to get
|
11075
|
+
* a pointer to the axis object through `chart.get()`.
|
11076
|
+
*
|
11077
|
+
* @type {String}
|
11078
|
+
* @sample {highcharts} highcharts/xaxis/id/
|
11079
|
+
* Get the object
|
11080
|
+
* @sample {highstock} stock/xaxis/id/
|
11081
|
+
* Get the object
|
11082
|
+
* @default null
|
11083
|
+
* @since 1.2.0
|
11084
|
+
* @apioption xAxis.id
|
11085
|
+
*/
|
10662
11086
|
|
10663
11087
|
/**
|
10664
11088
|
* The axis labels show the number or category for each tick.
|
@@ -10669,24 +11093,213 @@
|
|
10669
11093
|
* and can be enabled on X and Y axes too.
|
10670
11094
|
*/
|
10671
11095
|
labels: {
|
11096
|
+
/**
|
11097
|
+
* What part of the string the given position is anchored to.
|
11098
|
+
* If `left`, the left side of the string is at the axis position.
|
11099
|
+
* Can be one of `"left"`, `"center"` or `"right"`. Defaults to
|
11100
|
+
* an intelligent guess based on which side of the chart the axis
|
11101
|
+
* is on and the rotation of the label.
|
11102
|
+
*
|
11103
|
+
* @validvalue ["left", "center", "right"]
|
11104
|
+
* @type {String}
|
11105
|
+
* @sample {highcharts} highcharts/xaxis/labels-align-left/
|
11106
|
+
* Left
|
11107
|
+
* @sample {highcharts} highcharts/xaxis/labels-align-right/
|
11108
|
+
* Right
|
11109
|
+
* @apioption xAxis.labels.align
|
11110
|
+
*/
|
11111
|
+
// align: 'center',
|
11112
|
+
|
11113
|
+
/**
|
11114
|
+
* For horizontal axes, the allowed degrees of label rotation
|
11115
|
+
* to prevent overlapping labels. If there is enough space,
|
11116
|
+
* labels are not rotated. As the chart gets narrower, it
|
11117
|
+
* will start rotating the labels -45 degrees, then remove
|
11118
|
+
* every second label and try again with rotations 0 and -45 etc.
|
11119
|
+
* Set it to `false` to disable rotation, which will
|
11120
|
+
* cause the labels to word-wrap if possible.
|
11121
|
+
*
|
11122
|
+
* @type {Array<Number>}
|
11123
|
+
* @sample {highcharts|highstock}
|
11124
|
+
* highcharts/xaxis/labels-autorotation-default/
|
11125
|
+
* Default auto rotation of 0 or -45
|
11126
|
+
* @sample {highcharts|highstock}
|
11127
|
+
* highcharts/xaxis/labels-autorotation-0-90/
|
11128
|
+
* Custom graded auto rotation
|
11129
|
+
* @default [-45]
|
11130
|
+
* @since 4.1.0
|
11131
|
+
* @product highcharts highstock
|
11132
|
+
* @apioption xAxis.labels.autoRotation
|
11133
|
+
*/
|
11134
|
+
|
11135
|
+
/**
|
11136
|
+
* When each category width is more than this many pixels, we don't
|
11137
|
+
* apply auto rotation. Instead, we lay out the axis label with word
|
11138
|
+
* wrap. A lower limit makes sense when the label contains multiple
|
11139
|
+
* short words that don't extend the available horizontal space for
|
11140
|
+
* each label.
|
11141
|
+
*
|
11142
|
+
* @type {Number}
|
11143
|
+
* @sample {highcharts}
|
11144
|
+
* highcharts/xaxis/labels-autorotationlimit/
|
11145
|
+
* Lower limit
|
11146
|
+
* @default 80
|
11147
|
+
* @since 4.1.5
|
11148
|
+
* @product highcharts
|
11149
|
+
* @apioption xAxis.labels.autoRotationLimit
|
11150
|
+
*/
|
11151
|
+
|
11152
|
+
/**
|
11153
|
+
* Polar charts only. The label's pixel distance from the perimeter
|
11154
|
+
* of the plot area.
|
11155
|
+
*
|
11156
|
+
* @type {Number}
|
11157
|
+
* @default 15
|
11158
|
+
* @product highcharts
|
11159
|
+
* @apioption xAxis.labels.distance
|
11160
|
+
*/
|
10672
11161
|
|
10673
11162
|
/**
|
10674
11163
|
* Enable or disable the axis labels.
|
10675
11164
|
*
|
10676
|
-
* @type {Boolean}
|
10677
11165
|
* @sample {highcharts} highcharts/xaxis/labels-enabled/
|
10678
11166
|
* X axis labels disabled
|
10679
11167
|
* @sample {highstock} stock/xaxis/labels-enabled/
|
10680
11168
|
* X axis labels disabled
|
10681
|
-
* @default {highstock} true
|
11169
|
+
* @default {highcharts|highstock} true
|
10682
11170
|
* @default {highmaps} false
|
10683
11171
|
*/
|
10684
11172
|
enabled: true,
|
11173
|
+
|
11174
|
+
/**
|
11175
|
+
* A [format string](http://www.highcharts.com/docs/chart-
|
11176
|
+
* concepts/labels-and-string-formatting) for the axis label.
|
11177
|
+
*
|
11178
|
+
* @type {String}
|
11179
|
+
* @sample {highcharts|highstock} highcharts/yaxis/labels-format/
|
11180
|
+
* Add units to Y axis label
|
11181
|
+
* @default {value}
|
11182
|
+
* @since 3.0
|
11183
|
+
* @apioption xAxis.labels.format
|
11184
|
+
*/
|
11185
|
+
|
11186
|
+
/**
|
11187
|
+
* Callback JavaScript function to format the label. The value
|
11188
|
+
* is given by `this.value`. Additional properties for `this` are
|
11189
|
+
* `axis`, `chart`, `isFirst` and `isLast`. The value of the default
|
11190
|
+
* label formatter can be retrieved by calling
|
11191
|
+
* `this.axis.defaultLabelFormatter.call(this)` within the function.
|
11192
|
+
*
|
11193
|
+
* Defaults to:
|
11194
|
+
*
|
11195
|
+
* <pre>function() {
|
11196
|
+
* return this.value;
|
11197
|
+
* }</pre>
|
11198
|
+
*
|
11199
|
+
* @type {Function}
|
11200
|
+
* @sample {highcharts}
|
11201
|
+
* highcharts/xaxis/labels-formatter-linked/
|
11202
|
+
* Linked category names
|
11203
|
+
* @sample {highcharts}
|
11204
|
+
* highcharts/xaxis/labels-formatter-extended/
|
11205
|
+
* Modified numeric labels
|
11206
|
+
* @sample {highstock}
|
11207
|
+
* stock/xaxis/labels-formatter/
|
11208
|
+
* Added units on Y axis
|
11209
|
+
* @apioption xAxis.labels.formatter
|
11210
|
+
*/
|
11211
|
+
|
11212
|
+
/**
|
11213
|
+
* How to handle overflowing labels on horizontal axis. Can be
|
11214
|
+
* undefined, `false` or `"justify"`. By default it aligns inside
|
11215
|
+
* the chart area. If "justify", labels will not render outside
|
11216
|
+
* the plot area. If `false`, it will not be aligned at all.
|
11217
|
+
* If there is room to move it, it will be aligned to the edge,
|
11218
|
+
* else it will be removed.
|
11219
|
+
*
|
11220
|
+
* @deprecated
|
11221
|
+
* @validvalue [null, "justify"]
|
11222
|
+
* @type {String}
|
11223
|
+
* @since 2.2.5
|
11224
|
+
* @apioption xAxis.labels.overflow
|
11225
|
+
*/
|
11226
|
+
|
11227
|
+
/**
|
11228
|
+
* The pixel padding for axis labels, to ensure white space between
|
11229
|
+
* them.
|
11230
|
+
*
|
11231
|
+
* @type {Number}
|
11232
|
+
* @default 5
|
11233
|
+
* @product highcharts
|
11234
|
+
* @apioption xAxis.labels.padding
|
11235
|
+
*/
|
11236
|
+
|
11237
|
+
/**
|
11238
|
+
* Whether to reserve space for the labels. This can be turned off
|
11239
|
+
* when for example the labels are rendered inside the plot area
|
11240
|
+
* instead of outside.
|
11241
|
+
*
|
11242
|
+
* @type {Boolean}
|
11243
|
+
* @sample {highcharts} highcharts/xaxis/labels-reservespace/
|
11244
|
+
* No reserved space, labels inside plot
|
11245
|
+
* @default true
|
11246
|
+
* @since 4.1.10
|
11247
|
+
* @product highcharts
|
11248
|
+
* @apioption xAxis.labels.reserveSpace
|
11249
|
+
*/
|
11250
|
+
|
11251
|
+
/**
|
11252
|
+
* Rotation of the labels in degrees.
|
11253
|
+
*
|
11254
|
+
* @type {Number}
|
11255
|
+
* @sample {highcharts} highcharts/xaxis/labels-rotation/
|
11256
|
+
* X axis labels rotated 90°
|
11257
|
+
* @default 0
|
11258
|
+
* @apioption xAxis.labels.rotation
|
11259
|
+
*/
|
10685
11260
|
// rotation: 0,
|
10686
|
-
|
11261
|
+
|
11262
|
+
/**
|
11263
|
+
* Horizontal axes only. The number of lines to spread the labels
|
11264
|
+
* over to make room or tighter labels.
|
11265
|
+
*
|
11266
|
+
* @type {Number}
|
11267
|
+
* @sample {highcharts} highcharts/xaxis/labels-staggerlines/
|
11268
|
+
* Show labels over two lines
|
11269
|
+
* @sample {highstock} stock/xaxis/labels-staggerlines/
|
11270
|
+
* Show labels over two lines
|
11271
|
+
* @default null
|
11272
|
+
* @since 2.1
|
11273
|
+
* @apioption xAxis.labels.staggerLines
|
11274
|
+
*/
|
11275
|
+
|
11276
|
+
/**
|
11277
|
+
* To show only every _n_'th label on the axis, set the step to _n_.
|
11278
|
+
* Setting the step to 2 shows every other label.
|
11279
|
+
*
|
11280
|
+
* By default, the step is calculated automatically to avoid
|
11281
|
+
* overlap. To prevent this, set it to 1\. This usually only
|
11282
|
+
* happens on a category axis, and is often a sign that you have
|
11283
|
+
* chosen the wrong axis type.
|
11284
|
+
*
|
11285
|
+
* Read more at
|
11286
|
+
* [Axis docs](http://www.highcharts.com/docs/chart-concepts/axes)
|
11287
|
+
* => What axis should I use?
|
11288
|
+
*
|
11289
|
+
* @type {Number}
|
11290
|
+
* @sample {highcharts} highcharts/xaxis/labels-step/
|
11291
|
+
* Showing only every other axis label on a categorized
|
11292
|
+
* x axis
|
11293
|
+
* @sample {highcharts} highcharts/xaxis/labels-step-auto/
|
11294
|
+
* Auto steps on a category axis
|
11295
|
+
* @default null
|
11296
|
+
* @since 2.1
|
11297
|
+
* @apioption xAxis.labels.step
|
11298
|
+
*/
|
10687
11299
|
// step: null,
|
10688
11300
|
|
10689
11301
|
|
11302
|
+
|
10690
11303
|
/**
|
10691
11304
|
* CSS styles for the label. Use `whiteSpace: 'nowrap'` to prevent
|
10692
11305
|
* wrapping of category labels. Use `textOverflow: 'none'` to
|
@@ -10695,9 +11308,9 @@
|
|
10695
11308
|
* In styled mode, the labels are styled with the
|
10696
11309
|
* `.highcharts-axis-labels` class.
|
10697
11310
|
*
|
10698
|
-
* @type
|
10699
|
-
* @sample
|
10700
|
-
*
|
11311
|
+
* @type {CSSObject}
|
11312
|
+
* @sample {highcharts} highcharts/xaxis/labels-style/
|
11313
|
+
* Red X axis labels
|
10701
11314
|
*/
|
10702
11315
|
style: {
|
10703
11316
|
color: '#666666',
|
@@ -10706,38 +11319,86 @@
|
|
10706
11319
|
},
|
10707
11320
|
|
10708
11321
|
|
11322
|
+
/**
|
11323
|
+
* Whether to [use HTML](http://www.highcharts.com/docs/chart-
|
11324
|
+
* concepts/labels-and-string-formatting#html) to render the labels.
|
11325
|
+
*
|
11326
|
+
* @type {Boolean}
|
11327
|
+
* @default false
|
11328
|
+
* @apioption xAxis.labels.useHTML
|
11329
|
+
*/
|
11330
|
+
|
10709
11331
|
/**
|
10710
11332
|
* The x position offset of the label relative to the tick position
|
10711
11333
|
* on the axis.
|
10712
11334
|
*
|
10713
|
-
* @
|
10714
|
-
*
|
10715
|
-
* Y axis labels placed on grid lines
|
10716
|
-
* @default 0
|
11335
|
+
* @sample {highcharts} highcharts/xaxis/labels-x/
|
11336
|
+
* Y axis labels placed on grid lines
|
10717
11337
|
*/
|
10718
11338
|
x: 0
|
11339
|
+
|
11340
|
+
/**
|
11341
|
+
* The y position offset of the label relative to the tick position
|
11342
|
+
* on the axis. The default makes it adapt to the font size on
|
11343
|
+
* bottom axis.
|
11344
|
+
*
|
11345
|
+
* @type {Number}
|
11346
|
+
* @sample {highcharts} highcharts/xaxis/labels-x/
|
11347
|
+
* Y axis labels placed on grid lines
|
11348
|
+
* @default null
|
11349
|
+
* @apioption xAxis.labels.y
|
11350
|
+
*/
|
11351
|
+
|
11352
|
+
/**
|
11353
|
+
* The Z index for the axis labels.
|
11354
|
+
*
|
11355
|
+
* @type {Number}
|
11356
|
+
* @default 7
|
11357
|
+
* @apioption xAxis.labels.zIndex
|
11358
|
+
*/
|
10719
11359
|
},
|
10720
11360
|
|
10721
11361
|
/**
|
10722
|
-
*
|
10723
|
-
*
|
10724
|
-
*
|
10725
|
-
*
|
10726
|
-
*
|
10727
|
-
*
|
10728
|
-
* @type
|
10729
|
-
* @sample
|
10730
|
-
*
|
10731
|
-
* @sample
|
10732
|
-
*
|
10733
|
-
* @
|
10734
|
-
*
|
10735
|
-
* @
|
10736
|
-
* @
|
10737
|
-
|
10738
|
-
|
11362
|
+
* Index of another axis that this axis is linked to. When an axis is
|
11363
|
+
* linked to a master axis, it will take the same extremes as
|
11364
|
+
* the master, but as assigned by min or max or by setExtremes.
|
11365
|
+
* It can be used to show additional info, or to ease reading the
|
11366
|
+
* chart by duplicating the scales.
|
11367
|
+
*
|
11368
|
+
* @type {Number}
|
11369
|
+
* @sample {highcharts} highcharts/xaxis/linkedto/
|
11370
|
+
* Different string formats of the same date
|
11371
|
+
* @sample {highcharts} highcharts/yaxis/linkedto/
|
11372
|
+
* Y values on both sides
|
11373
|
+
* @default null
|
11374
|
+
* @since 2.0.2
|
11375
|
+
* @product highcharts highstock
|
11376
|
+
* @apioption xAxis.linkedTo
|
11377
|
+
*/
|
11378
|
+
|
11379
|
+
/**
|
11380
|
+
* The maximum value of the axis. If `null`, the max value is
|
11381
|
+
* automatically calculated.
|
11382
|
+
*
|
11383
|
+
* If the `endOnTick` option is true, the `max` value might
|
11384
|
+
* be rounded up.
|
11385
|
+
*
|
11386
|
+
* If a [tickAmount](#yAxis.tickAmount) is set, the axis may be extended
|
11387
|
+
* beyond the set max in order to reach the given number of ticks. The
|
11388
|
+
* same may happen in a chart with multiple axes, determined by [chart.
|
11389
|
+
* alignTicks](#chart), where a `tickAmount` is applied internally.
|
11390
|
+
*
|
11391
|
+
* @type {Number}
|
11392
|
+
* @sample {highcharts} highcharts/yaxis/max-200/
|
11393
|
+
* Y axis max of 200
|
11394
|
+
* @sample {highcharts} highcharts/yaxis/max-logarithmic/
|
11395
|
+
* Y axis max on logarithmic axis
|
11396
|
+
* @sample {highstock} stock/xaxis/min-max/
|
11397
|
+
* Fixed min and max on X axis
|
11398
|
+
* @sample {highmaps} maps/axis/min-max/
|
11399
|
+
* Pre-zoomed to a specific area
|
11400
|
+
* @apioption xAxis.max
|
10739
11401
|
*/
|
10740
|
-
minPadding: 0.01,
|
10741
11402
|
|
10742
11403
|
/**
|
10743
11404
|
* Padding of the max value relative to the length of the axis. A
|
@@ -10746,7 +11407,6 @@
|
|
10746
11407
|
* of the plot area. When the axis' `max` option is set or a max extreme
|
10747
11408
|
* is set using `axis.setExtremes()`, the maxPadding will be ignored.
|
10748
11409
|
*
|
10749
|
-
* @type {Number}
|
10750
11410
|
* @sample {highcharts} highcharts/yaxis/maxpadding/
|
10751
11411
|
* Max padding of 0.25 on y axis
|
10752
11412
|
* @sample {highstock} stock/xaxis/minpadding-maxpadding/
|
@@ -10754,19 +11414,101 @@
|
|
10754
11414
|
* @sample {highmaps} maps/chart/plotbackgroundcolor-gradient/
|
10755
11415
|
* Add some padding
|
10756
11416
|
* @default {highcharts} 0.01
|
10757
|
-
* @default {highstock} 0
|
10758
|
-
* @
|
10759
|
-
* @since 1.2.0
|
11417
|
+
* @default {highstock|highmaps} 0
|
11418
|
+
* @since 1.2.0
|
10760
11419
|
*/
|
10761
11420
|
maxPadding: 0.01,
|
10762
11421
|
|
11422
|
+
/**
|
11423
|
+
* Deprecated. Use `minRange` instead.
|
11424
|
+
*
|
11425
|
+
* @deprecated
|
11426
|
+
* @type {Number}
|
11427
|
+
* @product highcharts highstock
|
11428
|
+
* @apioption xAxis.maxZoom
|
11429
|
+
*/
|
11430
|
+
|
11431
|
+
/**
|
11432
|
+
* The minimum value of the axis. If `null` the min value is
|
11433
|
+
* automatically calculated.
|
11434
|
+
*
|
11435
|
+
* If the `startOnTick` option is true (default), the `min` value might
|
11436
|
+
* be rounded down.
|
11437
|
+
*
|
11438
|
+
* The automatically calculated minimum value is also affected by
|
11439
|
+
* [floor](#yAxis.floor), [softMin](#yAxis.softMin),
|
11440
|
+
* [minPadding](#yAxis.minPadding), [minRange](#yAxis.minRange)
|
11441
|
+
* as well as [series.threshold](#plotOptions.series.threshold)
|
11442
|
+
* and [series.softThreshold](#plotOptions.series.softThreshold).
|
11443
|
+
*
|
11444
|
+
* @type {Number}
|
11445
|
+
* @sample {highcharts} highcharts/yaxis/min-startontick-false/
|
11446
|
+
* -50 with startOnTick to false
|
11447
|
+
* @sample {highcharts} highcharts/yaxis/min-startontick-true/
|
11448
|
+
* -50 with startOnTick true by default
|
11449
|
+
* @sample {highstock} stock/xaxis/min-max/
|
11450
|
+
* Set min and max on X axis
|
11451
|
+
* @sample {highmaps} maps/axis/min-max/
|
11452
|
+
* Pre-zoomed to a specific area
|
11453
|
+
* @apioption xAxis.min
|
11454
|
+
*/
|
11455
|
+
|
11456
|
+
/**
|
11457
|
+
* The dash or dot style of the minor grid lines. For possible values,
|
11458
|
+
* see [this demonstration](http://jsfiddle.net/gh/get/library/pure/
|
11459
|
+
* highcharts/highcharts/tree/master/samples/highcharts/plotoptions/
|
11460
|
+
* series-dashstyle-all/).
|
11461
|
+
*
|
11462
|
+
* @validvalue ["Solid", "ShortDash", "ShortDot", "ShortDashDot",
|
11463
|
+
* "ShortDashDotDot", "Dot", "Dash" ,"LongDash",
|
11464
|
+
* "DashDot", "LongDashDot", "LongDashDotDot"]
|
11465
|
+
* @type {String}
|
11466
|
+
* @sample {highcharts} highcharts/yaxis/minorgridlinedashstyle/
|
11467
|
+
* Long dashes on minor grid lines
|
11468
|
+
* @sample {highstock} stock/xaxis/minorgridlinedashstyle/
|
11469
|
+
* Long dashes on minor grid lines
|
11470
|
+
* @default Solid
|
11471
|
+
* @since 1.2
|
11472
|
+
* @apioption xAxis.minorGridLineDashStyle
|
11473
|
+
*/
|
11474
|
+
|
11475
|
+
/**
|
11476
|
+
* Specific tick interval in axis units for the minor ticks.
|
11477
|
+
* On a linear axis, if `"auto"`, the minor tick interval is
|
11478
|
+
* calculated as a fifth of the tickInterval. If `null`, minor
|
11479
|
+
* ticks are not shown.
|
11480
|
+
*
|
11481
|
+
* On logarithmic axes, the unit is the power of the value. For example,
|
11482
|
+
* setting the minorTickInterval to 1 puts one tick on each of 0.1,
|
11483
|
+
* 1, 10, 100 etc. Setting the minorTickInterval to 0.1 produces 9
|
11484
|
+
* ticks between 1 and 10, 10 and 100 etc.
|
11485
|
+
*
|
11486
|
+
* If user settings dictate minor ticks to become too dense, they don't
|
11487
|
+
* make sense, and will be ignored to prevent performance problems.
|
11488
|
+
*
|
11489
|
+
* @type {Number|String}
|
11490
|
+
* @sample {highcharts} highcharts/yaxis/minortickinterval-null/
|
11491
|
+
* Null by default
|
11492
|
+
* @sample {highcharts} highcharts/yaxis/minortickinterval-5/
|
11493
|
+
* 5 units
|
11494
|
+
* @sample {highcharts} highcharts/yaxis/minortickinterval-log-auto/
|
11495
|
+
* "auto"
|
11496
|
+
* @sample {highcharts} highcharts/yaxis/minortickinterval-log/
|
11497
|
+
* 0.1
|
11498
|
+
* @sample {highstock} stock/demo/basic-line/
|
11499
|
+
* Null by default
|
11500
|
+
* @sample {highstock} stock/xaxis/minortickinterval-auto/
|
11501
|
+
* "auto"
|
11502
|
+
* @apioption xAxis.minorTickInterval
|
11503
|
+
*/
|
11504
|
+
|
10763
11505
|
/**
|
10764
11506
|
* The pixel length of the minor tick marks.
|
10765
11507
|
*
|
10766
|
-
* @
|
10767
|
-
*
|
10768
|
-
* @sample {highstock} stock/xaxis/minorticks/
|
10769
|
-
*
|
11508
|
+
* @sample {highcharts} highcharts/yaxis/minorticklength/
|
11509
|
+
* 10px on Y axis
|
11510
|
+
* @sample {highstock} stock/xaxis/minorticks/
|
11511
|
+
* 10px on Y axis
|
10770
11512
|
*/
|
10771
11513
|
minorTickLength: 2,
|
10772
11514
|
|
@@ -10775,21 +11517,175 @@
|
|
10775
11517
|
* Can be one of `inside` and `outside`.
|
10776
11518
|
*
|
10777
11519
|
* @validvalue ["inside", "outside"]
|
10778
|
-
* @
|
10779
|
-
*
|
10780
|
-
*
|
10781
|
-
*
|
10782
|
-
*
|
10783
|
-
*
|
10784
|
-
|
11520
|
+
* @sample {highcharts} highcharts/yaxis/minortickposition-outside/
|
11521
|
+
* Outside by default
|
11522
|
+
* @sample {highcharts} highcharts/yaxis/minortickposition-inside/
|
11523
|
+
* Inside
|
11524
|
+
* @sample {highstock} stock/xaxis/minorticks/
|
11525
|
+
* Inside
|
11526
|
+
*/
|
11527
|
+
minorTickPosition: 'outside',
|
11528
|
+
|
11529
|
+
/**
|
11530
|
+
* Enable or disable minor ticks. Unless
|
11531
|
+
* [minorTickInterval](#xAxis.minorTickInterval) is set, the tick
|
11532
|
+
* interval is calculated as a fifth of the `tickInterval`.
|
11533
|
+
*
|
11534
|
+
* On a logarithmic axis, minor ticks are laid out based on a best
|
11535
|
+
* guess, attempting to enter approximately 5 minor ticks between
|
11536
|
+
* each major tick.
|
11537
|
+
*
|
11538
|
+
* Prior to v6.0.0, ticks were unabled in auto layout by setting
|
11539
|
+
* `minorTickInterval` to `"auto"`.
|
11540
|
+
*
|
11541
|
+
* @productdesc {highcharts}
|
11542
|
+
* On axes using [categories](#xAxis.categories), minor ticks are not
|
11543
|
+
* supported.
|
11544
|
+
*
|
11545
|
+
* @type {Boolean}
|
11546
|
+
* @default false
|
11547
|
+
* @since 6.0.0
|
11548
|
+
* @sample {highcharts} highcharts/yaxis/minorticks-true/
|
11549
|
+
* Enabled on linear Y axis
|
11550
|
+
* @apioption xAxis.minorTicks
|
11551
|
+
*/
|
11552
|
+
|
11553
|
+
/**
|
11554
|
+
* The pixel width of the minor tick mark.
|
11555
|
+
*
|
11556
|
+
* @type {Number}
|
11557
|
+
* @sample {highcharts} highcharts/yaxis/minortickwidth/
|
11558
|
+
* 3px width
|
11559
|
+
* @sample {highstock} stock/xaxis/minorticks/
|
11560
|
+
* 1px width
|
11561
|
+
* @default 0
|
11562
|
+
* @apioption xAxis.minorTickWidth
|
11563
|
+
*/
|
11564
|
+
|
11565
|
+
/**
|
11566
|
+
* Padding of the min value relative to the length of the axis. A
|
11567
|
+
* padding of 0.05 will make a 100px axis 5px longer. This is useful
|
11568
|
+
* when you don't want the lowest data value to appear on the edge
|
11569
|
+
* of the plot area. When the axis' `min` option is set or a min extreme
|
11570
|
+
* is set using `axis.setExtremes()`, the minPadding will be ignored.
|
11571
|
+
*
|
11572
|
+
* @sample {highcharts} highcharts/yaxis/minpadding/
|
11573
|
+
* Min padding of 0.2
|
11574
|
+
* @sample {highstock} stock/xaxis/minpadding-maxpadding/
|
11575
|
+
* Greater min- and maxPadding
|
11576
|
+
* @sample {highmaps} maps/chart/plotbackgroundcolor-gradient/
|
11577
|
+
* Add some padding
|
11578
|
+
* @default {highcharts} 0.01
|
11579
|
+
* @default {highstock|highmaps} 0
|
11580
|
+
* @since 1.2.0
|
11581
|
+
*/
|
11582
|
+
minPadding: 0.01,
|
11583
|
+
|
11584
|
+
/**
|
11585
|
+
* The minimum range to display on this axis. The entire axis will not
|
11586
|
+
* be allowed to span over a smaller interval than this. For example,
|
11587
|
+
* for a datetime axis the main unit is milliseconds. If minRange is
|
11588
|
+
* set to 3600000, you can't zoom in more than to one hour.
|
11589
|
+
*
|
11590
|
+
* The default minRange for the x axis is five times the smallest
|
11591
|
+
* interval between any of the data points.
|
11592
|
+
*
|
11593
|
+
* On a logarithmic axis, the unit for the minimum range is the power.
|
11594
|
+
* So a minRange of 1 means that the axis can be zoomed to 10-100,
|
11595
|
+
* 100-1000, 1000-10000 etc.
|
11596
|
+
*
|
11597
|
+
* Note that the `minPadding`, `maxPadding`, `startOnTick` and
|
11598
|
+
* `endOnTick` settings also affect how the extremes of the axis
|
11599
|
+
* are computed.
|
11600
|
+
*
|
11601
|
+
* @type {Number}
|
11602
|
+
* @sample {highcharts} highcharts/xaxis/minrange/
|
11603
|
+
* Minimum range of 5
|
11604
|
+
* @sample {highstock} stock/xaxis/minrange/
|
11605
|
+
* Max zoom of 6 months overrides user selections
|
11606
|
+
* @sample {highmaps} maps/axis/minrange/
|
11607
|
+
* Minimum range of 1000
|
11608
|
+
* @apioption xAxis.minRange
|
11609
|
+
*/
|
11610
|
+
|
11611
|
+
/**
|
11612
|
+
* The minimum tick interval allowed in axis values. For example on
|
11613
|
+
* zooming in on an axis with daily data, this can be used to prevent
|
11614
|
+
* the axis from showing hours. Defaults to the closest distance between
|
11615
|
+
* two points on the axis.
|
11616
|
+
*
|
11617
|
+
* @type {Number}
|
11618
|
+
* @since 2.3.0
|
11619
|
+
* @apioption xAxis.minTickInterval
|
11620
|
+
*/
|
11621
|
+
|
11622
|
+
/**
|
11623
|
+
* The distance in pixels from the plot area to the axis line.
|
11624
|
+
* A positive offset moves the axis with it's line, labels and ticks
|
11625
|
+
* away from the plot area. This is typically used when two or more
|
11626
|
+
* axes are displayed on the same side of the plot. With multiple
|
11627
|
+
* axes the offset is dynamically adjusted to avoid collision, this
|
11628
|
+
* can be overridden by setting offset explicitly.
|
11629
|
+
*
|
11630
|
+
* @type {Number}
|
11631
|
+
* @sample {highcharts} highcharts/yaxis/offset/
|
11632
|
+
* Y axis offset of 70
|
11633
|
+
* @sample {highcharts} highcharts/yaxis/offset-centered/
|
11634
|
+
* Axes positioned in the center of the plot
|
11635
|
+
* @sample {highstock} stock/xaxis/offset/
|
11636
|
+
* Y axis offset by 70 px
|
11637
|
+
* @default 0
|
11638
|
+
* @apioption xAxis.offset
|
11639
|
+
*/
|
11640
|
+
|
11641
|
+
/**
|
11642
|
+
* Whether to display the axis on the opposite side of the normal. The
|
11643
|
+
* normal is on the left side for vertical axes and bottom for
|
11644
|
+
* horizontal, so the opposite sides will be right and top respectively.
|
11645
|
+
* This is typically used with dual or multiple axes.
|
11646
|
+
*
|
11647
|
+
* @type {Boolean}
|
11648
|
+
* @sample {highcharts} highcharts/yaxis/opposite/
|
11649
|
+
* Secondary Y axis opposite
|
11650
|
+
* @sample {highstock} stock/xaxis/opposite/
|
11651
|
+
* Y axis on left side
|
11652
|
+
* @default false
|
11653
|
+
* @apioption xAxis.opposite
|
11654
|
+
*/
|
11655
|
+
|
11656
|
+
/**
|
11657
|
+
* Whether to reverse the axis so that the highest number is closest
|
11658
|
+
* to the origin. If the chart is inverted, the x axis is reversed by
|
11659
|
+
* default.
|
11660
|
+
*
|
11661
|
+
* @type {Boolean}
|
11662
|
+
* @sample {highcharts} highcharts/yaxis/reversed/
|
11663
|
+
* Reversed Y axis
|
11664
|
+
* @sample {highstock} stock/xaxis/reversed/
|
11665
|
+
* Reversed Y axis
|
11666
|
+
* @default false
|
11667
|
+
* @apioption xAxis.reversed
|
11668
|
+
*/
|
11669
|
+
// reversed: false,
|
11670
|
+
|
11671
|
+
/**
|
11672
|
+
* Whether to show the last tick label. Defaults to `true` on cartesian
|
11673
|
+
* charts, and `false` on polar charts.
|
11674
|
+
*
|
11675
|
+
* @type {Boolean}
|
11676
|
+
* @sample {highcharts} highcharts/xaxis/showlastlabel-true/
|
11677
|
+
* Set to true on X axis
|
11678
|
+
* @sample {highstock} stock/xaxis/showfirstlabel/
|
11679
|
+
* Labels below plot lines on Y axis
|
11680
|
+
* @default true
|
11681
|
+
* @product highcharts highstock
|
11682
|
+
* @apioption xAxis.showLastLabel
|
10785
11683
|
*/
|
10786
|
-
minorTickPosition: 'outside', // inside or outside
|
10787
11684
|
|
10788
11685
|
/**
|
10789
11686
|
* For datetime axes, this decides where to put the tick between weeks.
|
10790
11687
|
* 0 = Sunday, 1 = Monday.
|
10791
11688
|
*
|
10792
|
-
* @type {Number}
|
10793
11689
|
* @sample {highcharts} highcharts/xaxis/startofweek-monday/
|
10794
11690
|
* Monday by default
|
10795
11691
|
* @sample {highcharts} highcharts/xaxis/startofweek-sunday/
|
@@ -10798,7 +11694,6 @@
|
|
10798
11694
|
* Monday by default
|
10799
11695
|
* @sample {highstock} stock/xaxis/startofweek-0
|
10800
11696
|
* Sunday
|
10801
|
-
* @default 1
|
10802
11697
|
* @product highcharts highstock
|
10803
11698
|
*/
|
10804
11699
|
startOfWeek: 1,
|
@@ -10811,27 +11706,23 @@
|
|
10811
11706
|
* In Highstock, `startOnTick` is always false when the navigator is
|
10812
11707
|
* enabled, to prevent jumpy scrolling.
|
10813
11708
|
*
|
10814
|
-
* @
|
10815
|
-
*
|
10816
|
-
*
|
10817
|
-
*
|
10818
|
-
*
|
10819
|
-
*
|
10820
|
-
*
|
10821
|
-
* @default false
|
10822
|
-
* @since 1.2.0
|
11709
|
+
* @sample {highcharts} highcharts/xaxis/startontick-false/
|
11710
|
+
* False by default
|
11711
|
+
* @sample {highcharts} highcharts/xaxis/startontick-true/
|
11712
|
+
* True
|
11713
|
+
* @sample {highstock} stock/xaxis/endontick/
|
11714
|
+
* False for Y axis
|
11715
|
+
* @since 1.2.0
|
10823
11716
|
*/
|
10824
11717
|
startOnTick: false,
|
10825
11718
|
|
10826
11719
|
/**
|
10827
11720
|
* The pixel length of the main tick marks.
|
10828
11721
|
*
|
10829
|
-
* @type {Number}
|
10830
11722
|
* @sample {highcharts} highcharts/xaxis/ticklength/
|
10831
11723
|
* 20 px tick length on the X axis
|
10832
11724
|
* @sample {highstock} stock/xaxis/ticks/
|
10833
11725
|
* Formatted ticks on X axis
|
10834
|
-
* @default 10
|
10835
11726
|
*/
|
10836
11727
|
tickLength: 10,
|
10837
11728
|
|
@@ -10842,28 +11733,22 @@
|
|
10842
11733
|
* else `on`.
|
10843
11734
|
*
|
10844
11735
|
* @validvalue [null, "on", "between"]
|
10845
|
-
* @
|
10846
|
-
*
|
10847
|
-
*
|
10848
|
-
*
|
10849
|
-
*
|
10850
|
-
* @default null
|
10851
|
-
* @product highcharts
|
11736
|
+
* @sample {highcharts} highcharts/xaxis/tickmarkplacement-between/
|
11737
|
+
* "between" by default
|
11738
|
+
* @sample {highcharts} highcharts/xaxis/tickmarkplacement-on/
|
11739
|
+
* "on"
|
11740
|
+
* @product highcharts
|
10852
11741
|
*/
|
10853
|
-
tickmarkPlacement: 'between',
|
11742
|
+
tickmarkPlacement: 'between',
|
10854
11743
|
|
10855
11744
|
/**
|
10856
11745
|
* If tickInterval is `null` this option sets the approximate pixel
|
10857
11746
|
* interval of the tick marks. Not applicable to categorized axis.
|
10858
11747
|
*
|
10859
|
-
*
|
10860
11748
|
* The tick interval is also influenced by the [minTickInterval](#xAxis.
|
10861
11749
|
* minTickInterval) option, that, by default prevents ticks from being
|
10862
11750
|
* denser than the data points.
|
10863
11751
|
*
|
10864
|
-
* Defaults to `72` for the Y axis and `100` for the X axis.
|
10865
|
-
*
|
10866
|
-
* @type {Number}
|
10867
11752
|
* @see [tickInterval](#xAxis.tickInterval),
|
10868
11753
|
* [tickPositioner](#xAxis.tickPositioner),
|
10869
11754
|
* [tickPositions](#xAxis.tickPositions).
|
@@ -10876,19 +11761,15 @@
|
|
10876
11761
|
|
10877
11762
|
/**
|
10878
11763
|
* The position of the major tick marks relative to the axis line.
|
10879
|
-
*
|
11764
|
+
* Can be one of `inside` and `outside`.
|
10880
11765
|
*
|
10881
11766
|
* @validvalue ["inside", "outside"]
|
10882
|
-
* @
|
10883
|
-
*
|
10884
|
-
*
|
10885
|
-
*
|
10886
|
-
*
|
10887
|
-
*
|
10888
|
-
* Formatted ticks on X axis
|
10889
|
-
* @default {highcharts} outside
|
10890
|
-
* @default {highstock} "outside"
|
10891
|
-
* @default {highmaps} outside
|
11767
|
+
* @sample {highcharts} highcharts/xaxis/tickposition-outside/
|
11768
|
+
* "outside" by default
|
11769
|
+
* @sample {highcharts} highcharts/xaxis/tickposition-inside/
|
11770
|
+
* "inside"
|
11771
|
+
* @sample {highstock} stock/xaxis/ticks/
|
11772
|
+
* Formatted ticks on X axis
|
10892
11773
|
*/
|
10893
11774
|
tickPosition: 'outside',
|
10894
11775
|
|
@@ -10907,22 +11788,18 @@
|
|
10907
11788
|
* values are "low", "middle" or "high".
|
10908
11789
|
*
|
10909
11790
|
* @validvalue ["low", "middle", "high"]
|
10910
|
-
* @
|
10911
|
-
*
|
10912
|
-
*
|
10913
|
-
*
|
10914
|
-
*
|
10915
|
-
*
|
10916
|
-
*
|
10917
|
-
*
|
10918
|
-
*
|
10919
|
-
*
|
10920
|
-
* Aligned to "high" value
|
10921
|
-
* @default {highcharts} middle
|
10922
|
-
* @default {highstock} "middle"
|
10923
|
-
* @default {highmaps} middle
|
11791
|
+
* @sample {highcharts} highcharts/xaxis/title-align-low/
|
11792
|
+
* "low"
|
11793
|
+
* @sample {highcharts} highcharts/xaxis/title-align-center/
|
11794
|
+
* "middle" by default
|
11795
|
+
* @sample {highcharts} highcharts/xaxis/title-align-high/
|
11796
|
+
* "high"
|
11797
|
+
* @sample {highcharts} highcharts/yaxis/title-offset/
|
11798
|
+
* Place the Y axis title on top of the axis
|
11799
|
+
* @sample {highstock} stock/xaxis/title-align/
|
11800
|
+
* Aligned to "high" value
|
10924
11801
|
*/
|
10925
|
-
align: 'middle',
|
11802
|
+
align: 'middle',
|
10926
11803
|
|
10927
11804
|
|
10928
11805
|
|
@@ -10932,13 +11809,14 @@
|
|
10932
11809
|
* be customized by setting `textOverflow: 'ellipsis'`, by
|
10933
11810
|
* setting a specific `width` or by setting `wordSpace: 'nowrap'`.
|
10934
11811
|
*
|
10935
|
-
*
|
10936
11812
|
* In styled mode, the stroke width is given in the
|
10937
11813
|
* `.highcharts-axis-title` class.
|
10938
11814
|
*
|
10939
|
-
* @type
|
10940
|
-
* @sample
|
10941
|
-
*
|
11815
|
+
* @type {CSSObject}
|
11816
|
+
* @sample {highcharts} highcharts/xaxis/title-style/
|
11817
|
+
* Red
|
11818
|
+
* @sample {highcharts} highcharts/css/axis/
|
11819
|
+
* Styled mode
|
10942
11820
|
* @default { "color": "#666666" }
|
10943
11821
|
*/
|
10944
11822
|
style: {
|
@@ -10957,21 +11835,19 @@
|
|
10957
11835
|
* defined.
|
10958
11836
|
*
|
10959
11837
|
* @validvalue ["linear", "logarithmic", "datetime", "category"]
|
10960
|
-
* @
|
10961
|
-
*
|
10962
|
-
*
|
10963
|
-
*
|
10964
|
-
*
|
10965
|
-
*
|
10966
|
-
*
|
10967
|
-
*
|
10968
|
-
*
|
10969
|
-
*
|
10970
|
-
*
|
10971
|
-
* @default linear
|
10972
|
-
* @product highcharts
|
11838
|
+
* @sample {highcharts} highcharts/xaxis/type-linear/
|
11839
|
+
* Linear
|
11840
|
+
* @sample {highcharts} highcharts/yaxis/type-log/
|
11841
|
+
* Logarithmic
|
11842
|
+
* @sample {highcharts} highcharts/yaxis/type-log-minorgrid/
|
11843
|
+
* Logarithmic with minor grid lines
|
11844
|
+
* @sample {highcharts} highcharts/xaxis/type-log-both/
|
11845
|
+
* Logarithmic on two axes
|
11846
|
+
* @sample {highcharts} highcharts/yaxis/type-log-negative/
|
11847
|
+
* Logarithmic with extension to emulate negative values
|
11848
|
+
* @product highcharts
|
10973
11849
|
*/
|
10974
|
-
type: 'linear',
|
11850
|
+
type: 'linear',
|
10975
11851
|
|
10976
11852
|
|
10977
11853
|
|
@@ -10981,15 +11857,13 @@
|
|
10981
11857
|
* In styled mode, the stroke width is given in the
|
10982
11858
|
* `.highcharts-minor-grid-line` class.
|
10983
11859
|
*
|
10984
|
-
* @type
|
10985
|
-
* @sample
|
10986
|
-
*
|
10987
|
-
* @sample
|
10988
|
-
*
|
10989
|
-
* @sample
|
10990
|
-
*
|
10991
|
-
* @sample {highstock} highcharts/css/axis-grid/
|
10992
|
-
* Styled mode
|
11860
|
+
* @type {Color}
|
11861
|
+
* @sample {highcharts} highcharts/yaxis/minorgridlinecolor/
|
11862
|
+
* Bright grey lines from Y axis
|
11863
|
+
* @sample {highcharts|highstock} highcharts/css/axis-grid/
|
11864
|
+
* Styled mode
|
11865
|
+
* @sample {highstock} stock/xaxis/minorgridlinecolor/
|
11866
|
+
* Bright grey lines from Y axis
|
10993
11867
|
* @default #f2f2f2
|
10994
11868
|
*/
|
10995
11869
|
minorGridLineColor: '#f2f2f2',
|
@@ -11001,27 +11875,23 @@
|
|
11001
11875
|
* In styled mode, the stroke width is given in the
|
11002
11876
|
* `.highcharts-grid-line` class.
|
11003
11877
|
*
|
11004
|
-
* @type {Number}
|
11005
11878
|
* @sample {highcharts} highcharts/yaxis/minorgridlinewidth/
|
11006
11879
|
* 2px lines from Y axis
|
11007
|
-
* @sample {highcharts} highcharts/css/axis-grid/
|
11880
|
+
* @sample {highcharts|highstock} highcharts/css/axis-grid/
|
11008
11881
|
* Styled mode
|
11009
11882
|
* @sample {highstock} stock/xaxis/minorgridlinewidth/
|
11010
11883
|
* 2px lines from Y axis
|
11011
|
-
* @sample {highstock} highcharts/css/axis-grid/
|
11012
|
-
* Styled mode
|
11013
|
-
* @default 1
|
11014
11884
|
*/
|
11015
11885
|
minorGridLineWidth: 1,
|
11016
11886
|
|
11017
11887
|
/**
|
11018
11888
|
* Color for the minor tick marks.
|
11019
11889
|
*
|
11020
|
-
* @type
|
11021
|
-
* @sample
|
11022
|
-
*
|
11023
|
-
* @sample
|
11024
|
-
*
|
11890
|
+
* @type {Color}
|
11891
|
+
* @sample {highcharts} highcharts/yaxis/minortickcolor/
|
11892
|
+
* Black tick marks on Y axis
|
11893
|
+
* @sample {highstock} stock/xaxis/minorticks/
|
11894
|
+
* Black tick marks on Y axis
|
11025
11895
|
* @default #999999
|
11026
11896
|
*/
|
11027
11897
|
minorTickColor: '#999999',
|
@@ -11033,13 +11903,16 @@
|
|
11033
11903
|
* `.highcharts-axis-line` or `.highcharts-xaxis-line` class.
|
11034
11904
|
*
|
11035
11905
|
* @productdesc {highmaps}
|
11036
|
-
* In Highmaps, the axis line is hidden by default
|
11037
|
-
*
|
11038
|
-
*
|
11039
|
-
* @
|
11040
|
-
* @sample
|
11041
|
-
*
|
11042
|
-
* @sample
|
11906
|
+
* In Highmaps, the axis line is hidden by default, because the axis is
|
11907
|
+
* not visible by default.
|
11908
|
+
*
|
11909
|
+
* @type {Color}
|
11910
|
+
* @sample {highcharts} highcharts/yaxis/linecolor/
|
11911
|
+
* A red line on Y axis
|
11912
|
+
* @sample {highcharts|highstock} highcharts/css/axis/
|
11913
|
+
* Axes in styled mode
|
11914
|
+
* @sample {highstock} stock/xaxis/linecolor/
|
11915
|
+
* A red line on X axis
|
11043
11916
|
* @default #ccd6eb
|
11044
11917
|
*/
|
11045
11918
|
lineColor: '#ccd6eb',
|
@@ -11050,13 +11923,13 @@
|
|
11050
11923
|
* In styled mode, the stroke width is given in the
|
11051
11924
|
* `.highcharts-axis-line` or `.highcharts-xaxis-line` class.
|
11052
11925
|
*
|
11053
|
-
* @
|
11054
|
-
*
|
11055
|
-
* @sample
|
11056
|
-
*
|
11057
|
-
* @sample
|
11058
|
-
*
|
11059
|
-
* @default {highstock} 1
|
11926
|
+
* @sample {highcharts} highcharts/yaxis/linecolor/
|
11927
|
+
* A 1px line on Y axis
|
11928
|
+
* @sample {highcharts|highstock} highcharts/css/axis/
|
11929
|
+
* Axes in styled mode
|
11930
|
+
* @sample {highstock} stock/xaxis/linewidth/
|
11931
|
+
* A 2px line on X axis
|
11932
|
+
* @default {highcharts|highstock} 1
|
11060
11933
|
* @default {highmaps} 0
|
11061
11934
|
*/
|
11062
11935
|
lineWidth: 1,
|
@@ -11070,15 +11943,35 @@
|
|
11070
11943
|
* @productdesc {highmaps}
|
11071
11944
|
* In Highmaps, the grid lines are hidden by default.
|
11072
11945
|
*
|
11073
|
-
* @type
|
11074
|
-
* @sample
|
11075
|
-
*
|
11076
|
-
* @sample
|
11077
|
-
*
|
11946
|
+
* @type {Color}
|
11947
|
+
* @sample {highcharts} highcharts/yaxis/gridlinecolor/
|
11948
|
+
* Green lines
|
11949
|
+
* @sample {highcharts|highstock} highcharts/css/axis-grid/
|
11950
|
+
* Styled mode
|
11951
|
+
* @sample {highstock} stock/xaxis/gridlinecolor/
|
11952
|
+
* Green lines
|
11078
11953
|
* @default #e6e6e6
|
11079
11954
|
*/
|
11080
11955
|
gridLineColor: '#e6e6e6',
|
11081
11956
|
// gridLineDashStyle: 'solid',
|
11957
|
+
|
11958
|
+
|
11959
|
+
/**
|
11960
|
+
* The width of the grid lines extending the ticks across the plot area.
|
11961
|
+
*
|
11962
|
+
* In styled mode, the stroke width is given in the
|
11963
|
+
* `.highcharts-grid-line` class.
|
11964
|
+
*
|
11965
|
+
* @type {Number}
|
11966
|
+
* @sample {highcharts} highcharts/yaxis/gridlinewidth/
|
11967
|
+
* 2px lines
|
11968
|
+
* @sample {highcharts|highstock} highcharts/css/axis-grid/
|
11969
|
+
* Styled mode
|
11970
|
+
* @sample {highstock} stock/xaxis/gridlinewidth/
|
11971
|
+
* 2px lines
|
11972
|
+
* @default 0
|
11973
|
+
* @apioption xAxis.gridLineWidth
|
11974
|
+
*/
|
11082
11975
|
// gridLineWidth: 0,
|
11083
11976
|
|
11084
11977
|
/**
|
@@ -11087,11 +11980,13 @@
|
|
11087
11980
|
* In styled mode, the stroke is given in the `.highcharts-tick`
|
11088
11981
|
* class.
|
11089
11982
|
*
|
11090
|
-
* @type
|
11091
|
-
* @sample
|
11092
|
-
*
|
11093
|
-
* @sample
|
11094
|
-
*
|
11983
|
+
* @type {Color}
|
11984
|
+
* @sample {highcharts} highcharts/xaxis/tickcolor/
|
11985
|
+
* Red ticks on X axis
|
11986
|
+
* @sample {highcharts|highstock} highcharts/css/axis-grid/
|
11987
|
+
* Styled mode
|
11988
|
+
* @sample {highstock} stock/xaxis/ticks/
|
11989
|
+
* Formatted ticks on X axis
|
11095
11990
|
* @default #ccd6eb
|
11096
11991
|
*/
|
11097
11992
|
tickColor: '#ccd6eb'
|
@@ -11106,64 +12001,104 @@
|
|
11106
12001
|
* configuration objects.
|
11107
12002
|
*
|
11108
12003
|
* See [the Axis object](#Axis) for programmatic access to the axis.
|
11109
|
-
*
|
12004
|
+
*
|
12005
|
+
* @extends xAxis
|
12006
|
+
* @excluding ordinal,overscroll
|
11110
12007
|
* @optionparent yAxis
|
11111
12008
|
*/
|
11112
12009
|
defaultYAxisOptions: {
|
11113
|
-
|
11114
12010
|
/**
|
11115
|
-
* Whether to force the axis to end on a tick. Use this option with
|
11116
|
-
* the `maxPadding` option to control the axis end.
|
11117
|
-
*
|
11118
12011
|
* @productdesc {highstock}
|
11119
12012
|
* In Highstock, `endOnTick` is always false when the navigator is
|
11120
12013
|
* enabled, to prevent jumpy scrolling.
|
11121
|
-
*
|
11122
|
-
* @type {Boolean}
|
11123
|
-
* @sample {highcharts} highcharts/chart/reflow-true/ True by default
|
11124
|
-
* @sample {highcharts} highcharts/yaxis/endontick-false/ False
|
11125
|
-
* @sample {highcharts} highcharts/yaxis/endontick-log-false/ False
|
11126
|
-
* @sample {highstock} stock/demo/basic-line/ True by default
|
11127
|
-
* @sample {highstock} stock/xaxis/endontick/ False
|
11128
|
-
* @default true
|
11129
|
-
* @since 1.2.0
|
11130
|
-
* @product highcharts highstock
|
11131
12014
|
*/
|
11132
12015
|
endOnTick: true,
|
11133
12016
|
|
11134
|
-
|
12017
|
+
/**
|
12018
|
+
* @productdesc {highstock}
|
12019
|
+
* In Highstock 1.x, the Y axis was placed on the left side by default.
|
12020
|
+
*
|
12021
|
+
* @sample {highcharts} highcharts/yaxis/opposite/
|
12022
|
+
* Secondary Y axis opposite
|
12023
|
+
* @sample {highstock} stock/xaxis/opposite/
|
12024
|
+
* Y axis on left side
|
12025
|
+
* @default {highstock} true
|
12026
|
+
* @default {highcharts} false
|
12027
|
+
* @product highstock highcharts
|
12028
|
+
* @apioption yAxis.opposite
|
12029
|
+
*/
|
11135
12030
|
|
11136
12031
|
/**
|
11137
|
-
*
|
11138
|
-
*
|
11139
|
-
*
|
11140
|
-
* @type {Boolean}
|
11141
|
-
* @sample {highcharts} highcharts/xaxis/showlastlabel-true/
|
11142
|
-
* Set to true on X axis
|
11143
|
-
* @sample {highstock} stock/xaxis/showfirstlabel/
|
11144
|
-
* Labels below plot lines on Y axis
|
11145
|
-
* @default false
|
11146
|
-
* @product highcharts highstock
|
12032
|
+
* @see [tickInterval](#xAxis.tickInterval),
|
12033
|
+
* [tickPositioner](#xAxis.tickPositioner),
|
12034
|
+
* [tickPositions](#xAxis.tickPositions).
|
11147
12035
|
*/
|
12036
|
+
tickPixelInterval: 72,
|
12037
|
+
|
11148
12038
|
showLastLabel: true,
|
11149
12039
|
|
11150
12040
|
/**
|
11151
12041
|
* @extends xAxis.labels
|
11152
12042
|
*/
|
11153
12043
|
labels: {
|
12044
|
+
/**
|
12045
|
+
* What part of the string the given position is anchored to. Can
|
12046
|
+
* be one of `"left"`, `"center"` or `"right"`. The exact position
|
12047
|
+
* also depends on the `labels.x` setting.
|
12048
|
+
*
|
12049
|
+
* Angular gauges and solid gauges defaults to `center`.
|
12050
|
+
*
|
12051
|
+
* @validvalue ["left", "center", "right"]
|
12052
|
+
* @type {String}
|
12053
|
+
* @sample {highcharts} highcharts/yaxis/labels-align-left/
|
12054
|
+
* Left
|
12055
|
+
* @default {highcharts|highmaps} right
|
12056
|
+
* @default {highstock} left
|
12057
|
+
* @apioption yAxis.labels.align
|
12058
|
+
*/
|
11154
12059
|
|
11155
12060
|
/**
|
11156
12061
|
* The x position offset of the label relative to the tick position
|
11157
12062
|
* on the axis. Defaults to -15 for left axis, 15 for right axis.
|
11158
12063
|
*
|
11159
|
-
* @type {Number}
|
11160
12064
|
* @sample {highcharts} highcharts/xaxis/labels-x/
|
11161
12065
|
* Y axis labels placed on grid lines
|
11162
|
-
* @default 0
|
11163
12066
|
*/
|
11164
12067
|
x: -8
|
11165
12068
|
},
|
11166
12069
|
|
12070
|
+
/**
|
12071
|
+
* @productdesc {highmaps}
|
12072
|
+
* In Highmaps, the axis line is hidden by default, because the axis is
|
12073
|
+
* not visible by default.
|
12074
|
+
*
|
12075
|
+
* @apioption yAxis.lineColor
|
12076
|
+
*/
|
12077
|
+
|
12078
|
+
/**
|
12079
|
+
* @sample {highcharts} highcharts/yaxis/min-startontick-false/
|
12080
|
+
* -50 with startOnTick to false
|
12081
|
+
* @sample {highcharts} highcharts/yaxis/min-startontick-true/
|
12082
|
+
* -50 with startOnTick true by default
|
12083
|
+
* @sample {highstock} stock/yaxis/min-max/
|
12084
|
+
* Fixed min and max on Y axis
|
12085
|
+
* @sample {highmaps} maps/axis/min-max/
|
12086
|
+
* Pre-zoomed to a specific area
|
12087
|
+
* @apioption yAxis.min
|
12088
|
+
*/
|
12089
|
+
|
12090
|
+
/**
|
12091
|
+
* @sample {highcharts} highcharts/yaxis/max-200/
|
12092
|
+
* Y axis max of 200
|
12093
|
+
* @sample {highcharts} highcharts/yaxis/max-logarithmic/
|
12094
|
+
* Y axis max on logarithmic axis
|
12095
|
+
* @sample {highstock} stock/yaxis/min-max/
|
12096
|
+
* Fixed min and max on Y axis
|
12097
|
+
* @sample {highmaps} maps/axis/min-max/
|
12098
|
+
* Pre-zoomed to a specific area
|
12099
|
+
* @apioption yAxis.max
|
12100
|
+
*/
|
12101
|
+
|
11167
12102
|
/**
|
11168
12103
|
* Padding of the max value relative to the length of the axis. A
|
11169
12104
|
* padding of 0.05 will make a 100px axis 5px longer. This is useful
|
@@ -11171,13 +12106,11 @@
|
|
11171
12106
|
* of the plot area. When the axis' `max` option is set or a max extreme
|
11172
12107
|
* is set using `axis.setExtremes()`, the maxPadding will be ignored.
|
11173
12108
|
*
|
11174
|
-
* @
|
11175
|
-
*
|
11176
|
-
*
|
11177
|
-
*
|
11178
|
-
*
|
11179
|
-
* @default 0.05
|
11180
|
-
* @since 1.2.0
|
12109
|
+
* @sample {highcharts} highcharts/yaxis/maxpadding-02/
|
12110
|
+
* Max padding of 0.2
|
12111
|
+
* @sample {highstock} stock/xaxis/minpadding-maxpadding/
|
12112
|
+
* Greater min- and maxPadding
|
12113
|
+
* @since 1.2.0
|
11181
12114
|
* @product highcharts highstock
|
11182
12115
|
*/
|
11183
12116
|
maxPadding: 0.05,
|
@@ -11189,13 +12122,11 @@
|
|
11189
12122
|
* of the plot area. When the axis' `min` option is set or a max extreme
|
11190
12123
|
* is set using `axis.setExtremes()`, the maxPadding will be ignored.
|
11191
12124
|
*
|
11192
|
-
* @
|
11193
|
-
*
|
11194
|
-
*
|
11195
|
-
*
|
11196
|
-
*
|
11197
|
-
* @default 0.05
|
11198
|
-
* @since 1.2.0
|
12125
|
+
* @sample {highcharts} highcharts/yaxis/minpadding/
|
12126
|
+
* Min padding of 0.2
|
12127
|
+
* @sample {highstock} stock/xaxis/minpadding-maxpadding/
|
12128
|
+
* Greater min- and maxPadding
|
12129
|
+
* @since 1.2.0
|
11199
12130
|
* @product highcharts highstock
|
11200
12131
|
*/
|
11201
12132
|
minPadding: 0.05,
|
@@ -11204,15 +12135,13 @@
|
|
11204
12135
|
* Whether to force the axis to start on a tick. Use this option with
|
11205
12136
|
* the `maxPadding` option to control the axis start.
|
11206
12137
|
*
|
11207
|
-
* @
|
11208
|
-
*
|
11209
|
-
*
|
11210
|
-
*
|
11211
|
-
*
|
11212
|
-
*
|
11213
|
-
*
|
11214
|
-
* @default true
|
11215
|
-
* @since 1.2.0
|
12138
|
+
* @sample {highcharts} highcharts/xaxis/startontick-false/
|
12139
|
+
* False by default
|
12140
|
+
* @sample {highcharts} highcharts/xaxis/startontick-true/
|
12141
|
+
* True
|
12142
|
+
* @sample {highstock} stock/xaxis/endontick/
|
12143
|
+
* False for Y axis
|
12144
|
+
* @since 1.2.0
|
11216
12145
|
* @product highcharts highstock
|
11217
12146
|
*/
|
11218
12147
|
startOnTick: true,
|
@@ -11226,9 +12155,8 @@
|
|
11226
12155
|
* The rotation of the text in degrees. 0 is horizontal, 270 is
|
11227
12156
|
* vertical reading from bottom to top.
|
11228
12157
|
*
|
11229
|
-
* @
|
11230
|
-
*
|
11231
|
-
* @default 270
|
12158
|
+
* @sample {highcharts} highcharts/yaxis/title-offset/
|
12159
|
+
* Horizontal
|
11232
12160
|
*/
|
11233
12161
|
rotation: 270,
|
11234
12162
|
|
@@ -11238,8 +12166,8 @@
|
|
11238
12166
|
* must be clean text. The Y axis title is disabled by setting the
|
11239
12167
|
* `text` option to `null`.
|
11240
12168
|
*
|
11241
|
-
* @
|
11242
|
-
*
|
12169
|
+
* @sample {highcharts} highcharts/xaxis/title-text/
|
12170
|
+
* Custom HTML
|
11243
12171
|
* @default {highcharts} Values
|
11244
12172
|
* @default {highstock} null
|
11245
12173
|
* @product highcharts highstock
|
@@ -11261,10 +12189,10 @@
|
|
11261
12189
|
/**
|
11262
12190
|
* Allow the stack labels to overlap.
|
11263
12191
|
*
|
11264
|
-
* @
|
11265
|
-
*
|
11266
|
-
*
|
11267
|
-
* @since
|
12192
|
+
* @sample {highcharts}
|
12193
|
+
* highcharts/yaxis/stacklabels-allowoverlap-false/
|
12194
|
+
* Default false
|
12195
|
+
* @since 5.0.13
|
11268
12196
|
* @product highcharts
|
11269
12197
|
*/
|
11270
12198
|
allowOverlap: false,
|
@@ -11272,26 +12200,23 @@
|
|
11272
12200
|
/**
|
11273
12201
|
* Enable or disable the stack total labels.
|
11274
12202
|
*
|
11275
|
-
* @
|
11276
|
-
*
|
11277
|
-
*
|
11278
|
-
* @since 2.1.5
|
12203
|
+
* @sample {highcharts} highcharts/yaxis/stacklabels-enabled/
|
12204
|
+
* Enabled stack total labels
|
12205
|
+
* @since 2.1.5
|
11279
12206
|
* @product highcharts
|
11280
12207
|
*/
|
11281
12208
|
enabled: false,
|
11282
12209
|
|
11283
12210
|
/**
|
11284
12211
|
* Callback JavaScript function to format the label. The value is
|
11285
|
-
* given by `this.total`.
|
11286
|
-
*
|
11287
|
-
*
|
11288
|
-
* return this.total;
|
11289
|
-
* }</pre>
|
12212
|
+
* given by `this.total`.
|
12213
|
+
*
|
12214
|
+
* @default function() { return this.total; }
|
11290
12215
|
*
|
11291
|
-
* @type
|
11292
|
-
* @sample
|
11293
|
-
*
|
11294
|
-
* @since
|
12216
|
+
* @type {Function}
|
12217
|
+
* @sample {highcharts} highcharts/yaxis/stacklabels-formatter/
|
12218
|
+
* Added units to stack total value
|
12219
|
+
* @since 2.1.5
|
11295
12220
|
* @product highcharts
|
11296
12221
|
*/
|
11297
12222
|
formatter: function() {
|
@@ -11305,10 +12230,10 @@
|
|
11305
12230
|
* In styled mode, the styles are set in the
|
11306
12231
|
* `.highcharts-stack-label` class.
|
11307
12232
|
*
|
11308
|
-
* @type
|
11309
|
-
* @sample
|
11310
|
-
*
|
11311
|
-
* @since
|
12233
|
+
* @type {CSSObject}
|
12234
|
+
* @sample {highcharts} highcharts/yaxis/stacklabels-style/
|
12235
|
+
* Red stack total labels
|
12236
|
+
* @since 2.1.5
|
11312
12237
|
* @product highcharts
|
11313
12238
|
*/
|
11314
12239
|
style: {
|
@@ -11320,31 +12245,7 @@
|
|
11320
12245
|
|
11321
12246
|
},
|
11322
12247
|
|
11323
|
-
|
11324
|
-
/**
|
11325
|
-
* The width of the grid lines extending the ticks across the plot
|
11326
|
-
* area.
|
11327
|
-
*
|
11328
|
-
* @productdesc {highmaps}
|
11329
|
-
* In Highmaps, the grid lines are hidden by default.
|
11330
|
-
*
|
11331
|
-
* @type {Number}
|
11332
|
-
* @sample {highcharts} highcharts/yaxis/gridlinewidth/ 2px lines
|
11333
|
-
* @sample {highstock} stock/xaxis/gridlinewidth/ 2px lines
|
11334
|
-
* @default 1
|
11335
|
-
* @product highcharts highstock
|
11336
|
-
*/
|
11337
12248
|
gridLineWidth: 1,
|
11338
|
-
|
11339
|
-
/**
|
11340
|
-
* The width of the line marking the axis itself.
|
11341
|
-
*
|
11342
|
-
* @type {Number}
|
11343
|
-
* @sample {highcharts} highcharts/yaxis/linecolor/ A 1px line on Y axis
|
11344
|
-
* @sample {highstock} stock/xaxis/linewidth/ A 2px line on X axis
|
11345
|
-
* @default 0
|
11346
|
-
* @product highcharts highstock
|
11347
|
-
*/
|
11348
12249
|
lineWidth: 0
|
11349
12250
|
// tickWidth: 0
|
11350
12251
|
|
@@ -11430,18 +12331,18 @@
|
|
11430
12331
|
/**
|
11431
12332
|
* The Chart that the axis belongs to.
|
11432
12333
|
*
|
11433
|
-
* @name
|
12334
|
+
* @name chart
|
11434
12335
|
* @memberOf Axis
|
11435
|
-
* @type
|
12336
|
+
* @type {Chart}
|
11436
12337
|
*/
|
11437
12338
|
axis.chart = chart;
|
11438
12339
|
|
11439
12340
|
/**
|
11440
12341
|
* Whether the axis is horizontal.
|
11441
12342
|
*
|
11442
|
-
* @name
|
12343
|
+
* @name horiz
|
11443
12344
|
* @memberOf Axis
|
11444
|
-
* @type
|
12345
|
+
* @type {Boolean}
|
11445
12346
|
*/
|
11446
12347
|
axis.horiz = chart.inverted && !axis.isZAxis ? !isXAxis : isXAxis;
|
11447
12348
|
|
@@ -11453,9 +12354,9 @@
|
|
11453
12354
|
* or `colorAxis`. Corresponds to properties on Chart, for example
|
11454
12355
|
* {@link Chart.xAxis}.
|
11455
12356
|
*
|
11456
|
-
* @name
|
12357
|
+
* @name coll
|
11457
12358
|
* @memberOf Axis
|
11458
|
-
* @type
|
12359
|
+
* @type {String}
|
11459
12360
|
*/
|
11460
12361
|
axis.coll = axis.coll || (isXAxis ? 'xAxis' : 'yAxis');
|
11461
12362
|
|
@@ -11466,9 +12367,9 @@
|
|
11466
12367
|
* The side on which the axis is rendered. 0 is top, 1 is right, 2 is
|
11467
12368
|
* bottom and 3 is left.
|
11468
12369
|
*
|
11469
|
-
* @name
|
12370
|
+
* @name side
|
11470
12371
|
* @memberOf Axis
|
11471
|
-
* @type
|
12372
|
+
* @type {Number}
|
11472
12373
|
*/
|
11473
12374
|
axis.side = userOptions.side || (axis.horiz ?
|
11474
12375
|
(axis.opposite ? 0 : 2) : // top : bottom
|
@@ -11495,9 +12396,9 @@
|
|
11495
12396
|
* Whether the axis is reversed. Based on the `axis.reversed`,
|
11496
12397
|
* option, but inverted charts have reversed xAxis by default.
|
11497
12398
|
*
|
11498
|
-
* @name
|
12399
|
+
* @name reversed
|
11499
12400
|
* @memberOf Axis
|
11500
|
-
* @type
|
12401
|
+
* @type {Boolean}
|
11501
12402
|
*/
|
11502
12403
|
axis.reversed = options.reversed;
|
11503
12404
|
axis.visible = options.visible !== false;
|
@@ -11549,9 +12450,9 @@
|
|
11549
12450
|
* logarithm of the real value, and the real value can be obtained from
|
11550
12451
|
* {@link Axis#getExtremes}.
|
11551
12452
|
*
|
11552
|
-
* @name
|
12453
|
+
* @name max
|
11553
12454
|
* @memberOf Axis
|
11554
|
-
* @type
|
12455
|
+
* @type {Number}
|
11555
12456
|
*/
|
11556
12457
|
axis.max = null;
|
11557
12458
|
/**
|
@@ -11559,9 +12460,9 @@
|
|
11559
12460
|
* logarithm of the real value, and the real value can be obtained from
|
11560
12461
|
* {@link Axis#getExtremes}.
|
11561
12462
|
*
|
11562
|
-
* @name
|
12463
|
+
* @name min
|
11563
12464
|
* @memberOf Axis
|
11564
|
-
* @type
|
12465
|
+
* @type {Number}
|
11565
12466
|
*/
|
11566
12467
|
axis.min = null;
|
11567
12468
|
|
@@ -11569,9 +12470,9 @@
|
|
11569
12470
|
/**
|
11570
12471
|
* The processed crosshair options.
|
11571
12472
|
*
|
11572
|
-
* @name
|
12473
|
+
* @name crosshair
|
11573
12474
|
* @memberOf Axis
|
11574
|
-
* @type
|
12475
|
+
* @type {AxisCrosshairOptions}
|
11575
12476
|
*/
|
11576
12477
|
axis.crosshair = pick(
|
11577
12478
|
options.crosshair,
|
@@ -11595,9 +12496,9 @@
|
|
11595
12496
|
/**
|
11596
12497
|
* All series associated to the axis.
|
11597
12498
|
*
|
11598
|
-
* @name
|
12499
|
+
* @name series
|
11599
12500
|
* @memberOf Axis
|
11600
|
-
* @type
|
12501
|
+
* @type {Array.<Series>}
|
11601
12502
|
*/
|
11602
12503
|
axis.series = axis.series || []; // populated by Series
|
11603
12504
|
|
@@ -11761,25 +12662,24 @@
|
|
11761
12662
|
// do this after we have already found seriesDataMin
|
11762
12663
|
// because in most cases all data is valid. #5234.
|
11763
12664
|
seriesDataMin = arrayMin(xData);
|
12665
|
+
seriesDataMax = arrayMax(xData);
|
12666
|
+
|
11764
12667
|
if (!isNumber(seriesDataMin) &&
|
11765
12668
|
!(seriesDataMin instanceof Date) // #5010
|
11766
12669
|
) {
|
11767
|
-
xData = grep(xData,
|
11768
|
-
return isNumber(x);
|
11769
|
-
});
|
12670
|
+
xData = grep(xData, isNumber);
|
11770
12671
|
// Do it again with valid data
|
11771
12672
|
seriesDataMin = arrayMin(xData);
|
11772
12673
|
}
|
11773
12674
|
|
11774
12675
|
axis.dataMin = Math.min(
|
11775
|
-
pick(axis.dataMin, xData[0]),
|
12676
|
+
pick(axis.dataMin, xData[0], seriesDataMin),
|
11776
12677
|
seriesDataMin
|
11777
12678
|
);
|
11778
12679
|
axis.dataMax = Math.max(
|
11779
|
-
pick(axis.dataMax, xData[0]),
|
11780
|
-
|
12680
|
+
pick(axis.dataMax, xData[0], seriesDataMax),
|
12681
|
+
seriesDataMax
|
11781
12682
|
);
|
11782
|
-
|
11783
12683
|
}
|
11784
12684
|
|
11785
12685
|
// Get dataMin and dataMax for Y axes, as well as handle
|
@@ -11962,8 +12862,8 @@
|
|
11962
12862
|
skip,
|
11963
12863
|
transB = axis.transB,
|
11964
12864
|
/**
|
11965
|
-
* Check if x is between a and b. If not, either move to a/b
|
11966
|
-
* depending on the force parameter.
|
12865
|
+
* Check if x is between a and b. If not, either move to a/b
|
12866
|
+
* or skip, depending on the force parameter.
|
11967
12867
|
*/
|
11968
12868
|
between = function(x, a, b) {
|
11969
12869
|
if (x < a || x > b) {
|
@@ -12023,7 +12923,14 @@
|
|
12023
12923
|
correctFloat(Math.floor(min / tickInterval) * tickInterval),
|
12024
12924
|
roundedMax =
|
12025
12925
|
correctFloat(Math.ceil(max / tickInterval) * tickInterval),
|
12026
|
-
tickPositions = []
|
12926
|
+
tickPositions = [],
|
12927
|
+
precision;
|
12928
|
+
|
12929
|
+
// When the precision is higher than what we filter out in
|
12930
|
+
// correctFloat, skip it (#6183).
|
12931
|
+
if (correctFloat(roundedMin + tickInterval) === roundedMin) {
|
12932
|
+
precision = 20;
|
12933
|
+
}
|
12027
12934
|
|
12028
12935
|
// For single points, add a tick regardless of the relative position
|
12029
12936
|
// (#2662, #6274)
|
@@ -12039,7 +12946,10 @@
|
|
12039
12946
|
tickPositions.push(pos);
|
12040
12947
|
|
12041
12948
|
// Always add the raw tickInterval, not the corrected one.
|
12042
|
-
pos = correctFloat(
|
12949
|
+
pos = correctFloat(
|
12950
|
+
pos + tickInterval,
|
12951
|
+
precision
|
12952
|
+
);
|
12043
12953
|
|
12044
12954
|
// If the interval is not big enough in the current min - max range
|
12045
12955
|
// to actually increase the loop variable, we need to break out to
|
@@ -12648,8 +13558,11 @@
|
|
12648
13558
|
);
|
12649
13559
|
}
|
12650
13560
|
|
12651
|
-
|
12652
|
-
|
13561
|
+
/**
|
13562
|
+
* Now we're finished detecting min and max, crop and group series data.
|
13563
|
+
* This is in turn needed in order to find tick positions in
|
13564
|
+
* ordinal axes.
|
13565
|
+
*/
|
12653
13566
|
if (isXAxis && !secondPass) {
|
12654
13567
|
each(axis.series, function(series) {
|
12655
13568
|
series.processData(
|
@@ -12794,6 +13707,10 @@
|
|
12794
13707
|
// Too dense ticks, keep only the first and last (#4477)
|
12795
13708
|
if (tickPositions.length > this.len) {
|
12796
13709
|
tickPositions = [tickPositions[0], tickPositions.pop()];
|
13710
|
+
// Reduce doubled value (#7339)
|
13711
|
+
if (tickPositions[0] === tickPositions[1]) {
|
13712
|
+
tickPositions.length = 1;
|
13713
|
+
}
|
12797
13714
|
}
|
12798
13715
|
|
12799
13716
|
this.tickPositions = tickPositions;
|
@@ -13229,26 +14146,28 @@
|
|
13229
14146
|
|
13230
14147
|
/**
|
13231
14148
|
* The returned object literal from the {@link Highcharts.Axis#getExtremes}
|
13232
|
-
* function.
|
13233
|
-
*
|
14149
|
+
* function.
|
14150
|
+
*
|
14151
|
+
* @typedef {Object} Extremes
|
13234
14152
|
* @property {Number} dataMax
|
13235
|
-
*
|
14153
|
+
* The maximum value of the axis' associated series.
|
13236
14154
|
* @property {Number} dataMin
|
13237
|
-
*
|
14155
|
+
* The minimum value of the axis' associated series.
|
13238
14156
|
* @property {Number} max
|
13239
|
-
*
|
13240
|
-
*
|
13241
|
-
*
|
14157
|
+
* The maximum axis value, either automatic or set manually. If
|
14158
|
+
* the `max` option is not set, `maxPadding` is 0 and `endOnTick`
|
14159
|
+
* is false, this value will be the same as `dataMax`.
|
13242
14160
|
* @property {Number} min
|
13243
|
-
*
|
13244
|
-
*
|
13245
|
-
*
|
14161
|
+
* The minimum axis value, either automatic or set manually. If
|
14162
|
+
* the `min` option is not set, `minPadding` is 0 and
|
14163
|
+
* `startOnTick` is false, this value will be the same
|
14164
|
+
* as `dataMin`.
|
13246
14165
|
*/
|
13247
14166
|
/**
|
13248
14167
|
* Get the current extremes for the axis.
|
13249
14168
|
*
|
13250
14169
|
* @returns {Extremes}
|
13251
|
-
*
|
14170
|
+
* An object containing extremes information.
|
13252
14171
|
*
|
13253
14172
|
* @sample highcharts/members/axis-getextremes/
|
13254
14173
|
* Report extremes by click on a button
|
@@ -13393,21 +14312,31 @@
|
|
13393
14312
|
};
|
13394
14313
|
|
13395
14314
|
if (horiz) {
|
13396
|
-
autoRotation = !labelOptions.staggerLines &&
|
13397
|
-
|
13398
|
-
|
13399
|
-
|
14315
|
+
autoRotation = !labelOptions.staggerLines &&
|
14316
|
+
!labelOptions.step &&
|
14317
|
+
( // #3971
|
14318
|
+
defined(rotationOption) ? [rotationOption] :
|
14319
|
+
slotSize < pick(labelOptions.autoRotationLimit, 80) &&
|
14320
|
+
labelOptions.autoRotation
|
14321
|
+
);
|
13400
14322
|
|
13401
14323
|
if (autoRotation) {
|
13402
14324
|
|
13403
|
-
// Loop over the given autoRotation options, and determine
|
13404
|
-
//
|
14325
|
+
// Loop over the given autoRotation options, and determine
|
14326
|
+
// which gives the best score. The best score is that with
|
14327
|
+
// the lowest number of steps and a rotation closest
|
14328
|
+
// to horizontal.
|
13405
14329
|
each(autoRotation, function(rot) {
|
13406
14330
|
var score;
|
13407
14331
|
|
13408
|
-
if (
|
14332
|
+
if (
|
14333
|
+
rot === rotationOption ||
|
14334
|
+
(rot && rot >= -90 && rot <= 90)
|
14335
|
+
) { // #3891
|
13409
14336
|
|
13410
|
-
step = getStep(
|
14337
|
+
step = getStep(
|
14338
|
+
Math.abs(labelMetrics.h / Math.sin(deg2rad * rot))
|
14339
|
+
);
|
13411
14340
|
|
13412
14341
|
score = step + Math.abs(rot / 360);
|
13413
14342
|
|
@@ -13457,8 +14386,14 @@
|
|
13457
14386
|
((this.staggerLines || 1) * this.len) / slotCount
|
13458
14387
|
) || (!horiz && (
|
13459
14388
|
// #7028
|
13460
|
-
(
|
13461
|
-
|
14389
|
+
(
|
14390
|
+
labelOptions.style &&
|
14391
|
+
parseInt(labelOptions.style.width, 10)
|
14392
|
+
) ||
|
14393
|
+
(
|
14394
|
+
marginLeft &&
|
14395
|
+
(marginLeft - chart.spacing[3])
|
14396
|
+
) ||
|
13462
14397
|
chart.chartWidth * 0.33
|
13463
14398
|
));
|
13464
14399
|
|
@@ -13478,10 +14413,14 @@
|
|
13478
14413
|
labelOptions = this.options.labels,
|
13479
14414
|
horiz = this.horiz,
|
13480
14415
|
slotWidth = this.getSlotWidth(),
|
13481
|
-
innerWidth = Math.max(
|
14416
|
+
innerWidth = Math.max(
|
14417
|
+
1,
|
14418
|
+
Math.round(slotWidth - 2 * (labelOptions.padding || 5))
|
14419
|
+
),
|
13482
14420
|
attr = {},
|
13483
14421
|
labelMetrics = this.labelMetrics(),
|
13484
|
-
textOverflowOption = labelOptions.style &&
|
14422
|
+
textOverflowOption = labelOptions.style &&
|
14423
|
+
labelOptions.style.textOverflow,
|
13485
14424
|
css,
|
13486
14425
|
maxLabelLength = 0,
|
13487
14426
|
label,
|
@@ -13508,7 +14447,10 @@
|
|
13508
14447
|
|
13509
14448
|
// Apply rotation only if the label is too wide for the slot, and
|
13510
14449
|
// the label is wider than its height.
|
13511
|
-
if (
|
14450
|
+
if (
|
14451
|
+
maxLabelLength > innerWidth &&
|
14452
|
+
maxLabelLength > labelMetrics.h
|
14453
|
+
) {
|
13512
14454
|
attr.rotation = this.labelRotation;
|
13513
14455
|
} else {
|
13514
14456
|
this.labelRotation = 0;
|
@@ -13524,26 +14466,37 @@
|
|
13524
14466
|
if (!textOverflowOption) {
|
13525
14467
|
css.textOverflow = 'clip';
|
13526
14468
|
|
13527
|
-
// On vertical axis, only allow word wrap if there is room
|
14469
|
+
// On vertical axis, only allow word wrap if there is room
|
14470
|
+
// for more lines.
|
13528
14471
|
i = tickPositions.length;
|
13529
14472
|
while (!horiz && i--) {
|
13530
14473
|
pos = tickPositions[i];
|
13531
14474
|
label = ticks[pos].label;
|
13532
14475
|
if (label) {
|
13533
|
-
// Reset ellipsis in order to get the correct
|
13534
|
-
|
14476
|
+
// Reset ellipsis in order to get the correct
|
14477
|
+
// bounding box (#4070)
|
14478
|
+
if (
|
14479
|
+
label.styles &&
|
14480
|
+
label.styles.textOverflow === 'ellipsis'
|
14481
|
+
) {
|
13535
14482
|
label.css({
|
13536
14483
|
textOverflow: 'clip'
|
13537
14484
|
});
|
13538
14485
|
|
13539
|
-
// Set the correct width in order to read
|
14486
|
+
// Set the correct width in order to read
|
14487
|
+
// the bounding box height (#4678, #5034)
|
13540
14488
|
} else if (ticks[pos].labelLength > slotWidth) {
|
13541
14489
|
label.css({
|
13542
14490
|
width: slotWidth + 'px'
|
13543
14491
|
});
|
13544
14492
|
}
|
13545
14493
|
|
13546
|
-
if (
|
14494
|
+
if (
|
14495
|
+
label.getBBox().height > (
|
14496
|
+
this.len / tickPositions.length -
|
14497
|
+
(labelMetrics.h - labelMetrics.f)
|
14498
|
+
)
|
14499
|
+
) {
|
13547
14500
|
label.specCss = {
|
13548
14501
|
textOverflow: 'ellipsis'
|
13549
14502
|
};
|
@@ -13557,7 +14510,11 @@
|
|
13557
14510
|
// Add ellipsis if the label length is significantly longer than ideal
|
13558
14511
|
if (attr.rotation) {
|
13559
14512
|
css = {
|
13560
|
-
width: (
|
14513
|
+
width: (
|
14514
|
+
maxLabelLength > chart.chartHeight * 0.5 ?
|
14515
|
+
chart.chartHeight * 0.33 :
|
14516
|
+
chart.chartHeight
|
14517
|
+
) + 'px'
|
13561
14518
|
};
|
13562
14519
|
if (!textOverflowOption) {
|
13563
14520
|
css.textOverflow = 'ellipsis';
|
@@ -13565,7 +14522,8 @@
|
|
13565
14522
|
}
|
13566
14523
|
|
13567
14524
|
// Set the explicit or automatic label alignment
|
13568
|
-
this.labelAlign = labelOptions.align ||
|
14525
|
+
this.labelAlign = labelOptions.align ||
|
14526
|
+
this.autoLabelAlign(this.labelRotation);
|
13569
14527
|
if (this.labelAlign) {
|
13570
14528
|
attr.align = this.labelAlign;
|
13571
14529
|
}
|
@@ -13575,7 +14533,9 @@
|
|
13575
14533
|
var tick = ticks[pos],
|
13576
14534
|
label = tick && tick.label;
|
13577
14535
|
if (label) {
|
13578
|
-
|
14536
|
+
// This needs to go before the CSS in old IE (#4502)
|
14537
|
+
label.attr(attr);
|
14538
|
+
|
13579
14539
|
if (css) {
|
13580
14540
|
label.css(merge(css, label.specCss));
|
13581
14541
|
}
|
@@ -13585,7 +14545,11 @@
|
|
13585
14545
|
});
|
13586
14546
|
|
13587
14547
|
// Note: Why is this not part of getLabelPosition?
|
13588
|
-
this.tickRotCorr = renderer.rotCorr(
|
14548
|
+
this.tickRotCorr = renderer.rotCorr(
|
14549
|
+
labelMetrics.b,
|
14550
|
+
this.labelRotation || 0,
|
14551
|
+
this.side !== 0
|
14552
|
+
);
|
13589
14553
|
},
|
13590
14554
|
|
13591
14555
|
/**
|
@@ -13599,7 +14563,12 @@
|
|
13599
14563
|
hasData: function() {
|
13600
14564
|
return (
|
13601
14565
|
this.hasVisibleSeries ||
|
13602
|
-
(
|
14566
|
+
(
|
14567
|
+
defined(this.min) &&
|
14568
|
+
defined(this.max) &&
|
14569
|
+
this.tickPositions &&
|
14570
|
+
this.tickPositions.length > 0
|
14571
|
+
)
|
13603
14572
|
);
|
13604
14573
|
},
|
13605
14574
|
|
@@ -13668,10 +14637,10 @@
|
|
13668
14637
|
* Generates a tick for initial positioning.
|
13669
14638
|
*
|
13670
14639
|
* @private
|
13671
|
-
* @param
|
13672
|
-
*
|
13673
|
-
* @param
|
13674
|
-
*
|
14640
|
+
* @param {number} pos
|
14641
|
+
* The tick position in axis values.
|
14642
|
+
* @param {number} i
|
14643
|
+
* The index of the tick in {@link Axis.tickPositions}.
|
13675
14644
|
*/
|
13676
14645
|
generateTick: function(pos) {
|
13677
14646
|
var ticks = this.ticks;
|
@@ -13697,7 +14666,8 @@
|
|
13697
14666
|
ticks = axis.ticks,
|
13698
14667
|
horiz = axis.horiz,
|
13699
14668
|
side = axis.side,
|
13700
|
-
invertedSide = chart.inverted &&
|
14669
|
+
invertedSide = chart.inverted &&
|
14670
|
+
!axis.isZAxis ? [1, 0, 3, 2][side] : side,
|
13701
14671
|
hasData,
|
13702
14672
|
showAxis,
|
13703
14673
|
titleOffset = 0,
|
@@ -13729,19 +14699,28 @@
|
|
13729
14699
|
.attr({
|
13730
14700
|
zIndex: options.gridZIndex || 1
|
13731
14701
|
})
|
13732
|
-
.addClass(
|
14702
|
+
.addClass(
|
14703
|
+
'highcharts-' + this.coll.toLowerCase() + '-grid ' +
|
14704
|
+
(className || '')
|
14705
|
+
)
|
13733
14706
|
.add(axisParent);
|
13734
14707
|
axis.axisGroup = renderer.g('axis')
|
13735
14708
|
.attr({
|
13736
14709
|
zIndex: options.zIndex || 2
|
13737
14710
|
})
|
13738
|
-
.addClass(
|
14711
|
+
.addClass(
|
14712
|
+
'highcharts-' + this.coll.toLowerCase() + ' ' +
|
14713
|
+
(className || '')
|
14714
|
+
)
|
13739
14715
|
.add(axisParent);
|
13740
14716
|
axis.labelGroup = renderer.g('axis-labels')
|
13741
14717
|
.attr({
|
13742
14718
|
zIndex: labelOptions.zIndex || 7
|
13743
14719
|
})
|
13744
|
-
.addClass(
|
14720
|
+
.addClass(
|
14721
|
+
'highcharts-' + axis.coll.toLowerCase() + '-labels ' +
|
14722
|
+
(className || '')
|
14723
|
+
)
|
13745
14724
|
.add(axisParent);
|
13746
14725
|
}
|
13747
14726
|
|
@@ -13756,13 +14735,20 @@
|
|
13756
14735
|
axis.renderUnsquish();
|
13757
14736
|
|
13758
14737
|
|
13759
|
-
// Left side must be align: right and right side must
|
13760
|
-
|
13761
|
-
|
13762
|
-
|
13763
|
-
|
14738
|
+
// Left side must be align: right and right side must
|
14739
|
+
// have align: left for labels
|
14740
|
+
if (
|
14741
|
+
labelOptions.reserveSpace !== false &&
|
14742
|
+
(
|
14743
|
+
side === 0 ||
|
14744
|
+
side === 2 || {
|
14745
|
+
1: 'left',
|
14746
|
+
3: 'right'
|
14747
|
+
}[side] === axis.labelAlign ||
|
14748
|
+
axis.labelAlign === 'center'
|
14749
|
+
)
|
14750
|
+
) {
|
13764
14751
|
each(tickPositions, function(pos) {
|
13765
|
-
|
13766
14752
|
// get the highest offset
|
13767
14753
|
labelOffset = Math.max(
|
13768
14754
|
ticks[pos].getLabelSize(),
|
@@ -13776,7 +14762,6 @@
|
|
13776
14762
|
axis.labelOffset = labelOffset * (axis.opposite ? -1 : 1);
|
13777
14763
|
}
|
13778
14764
|
|
13779
|
-
|
13780
14765
|
} else { // doesn't have data
|
13781
14766
|
objectEach(ticks, function(tick, n) {
|
13782
14767
|
tick.destroy();
|
@@ -13784,14 +14769,20 @@
|
|
13784
14769
|
});
|
13785
14770
|
}
|
13786
14771
|
|
13787
|
-
if (
|
14772
|
+
if (
|
14773
|
+
axisTitleOptions &&
|
14774
|
+
axisTitleOptions.text &&
|
14775
|
+
axisTitleOptions.enabled !== false
|
14776
|
+
) {
|
13788
14777
|
axis.addTitle(showAxis);
|
13789
14778
|
|
13790
14779
|
if (showAxis && axisTitleOptions.reserveSpace !== false) {
|
13791
14780
|
axis.titleOffset = titleOffset =
|
13792
14781
|
axis.axisTitle.getBBox()[horiz ? 'height' : 'width'];
|
13793
14782
|
titleOffsetOption = axisTitleOptions.offset;
|
13794
|
-
titleMargin = defined(titleOffsetOption) ?
|
14783
|
+
titleMargin = defined(titleOffsetOption) ?
|
14784
|
+
0 :
|
14785
|
+
pick(axisTitleOptions.margin, horiz ? 5 : 10);
|
13795
14786
|
}
|
13796
14787
|
}
|
13797
14788
|
|
@@ -13817,8 +14808,16 @@
|
|
13817
14808
|
labelOffsetPadded = Math.abs(labelOffset) + titleMargin;
|
13818
14809
|
if (labelOffset) {
|
13819
14810
|
labelOffsetPadded -= lineHeightCorrection;
|
13820
|
-
labelOffsetPadded += directionFactor * (
|
14811
|
+
labelOffsetPadded += directionFactor * (
|
14812
|
+
horiz ?
|
14813
|
+
pick(
|
14814
|
+
labelOptions.y,
|
14815
|
+
axis.tickRotCorr.y + directionFactor * 8
|
14816
|
+
) :
|
14817
|
+
labelOptions.x
|
14818
|
+
);
|
13821
14819
|
}
|
14820
|
+
|
13822
14821
|
axis.axisTitleMargin = pick(titleOffsetOption, labelOffsetPadded);
|
13823
14822
|
|
13824
14823
|
axisOffset[side] = Math.max(
|
@@ -13830,8 +14829,11 @@
|
|
13830
14829
|
0 // #4866
|
13831
14830
|
);
|
13832
14831
|
|
13833
|
-
// Decide the clipping needed to keep the graph inside
|
13834
|
-
|
14832
|
+
// Decide the clipping needed to keep the graph inside
|
14833
|
+
// the plot area and axis lines
|
14834
|
+
clip = options.offset ?
|
14835
|
+
0 :
|
14836
|
+
Math.floor(axis.axisLine.strokeWidth() / 2) * 2; // #4308, #4371
|
13835
14837
|
clipOffset[invertedSide] = Math.max(clipOffset[invertedSide], clip);
|
13836
14838
|
},
|
13837
14839
|
|
@@ -14062,8 +15064,9 @@
|
|
14062
15064
|
each(tickPositions, function(pos, i) {
|
14063
15065
|
axis.renderTick(pos, i);
|
14064
15066
|
});
|
14065
|
-
// In a categorized axis, the tick marks are displayed
|
14066
|
-
// we need to add a tick mark and
|
15067
|
+
// In a categorized axis, the tick marks are displayed
|
15068
|
+
// between labels. So we need to add a tick mark and
|
15069
|
+
// grid line at the left edge of the X axis.
|
14067
15070
|
if (tickmarkOffset && (axis.min === 0 || axis.single)) {
|
14068
15071
|
if (!ticks[-1]) {
|
14069
15072
|
ticks[-1] = new Tick(axis, -1, null, true);
|
@@ -14076,8 +15079,19 @@
|
|
14076
15079
|
// alternate grid color
|
14077
15080
|
if (alternateGridColor) {
|
14078
15081
|
each(tickPositions, function(pos, i) {
|
14079
|
-
to = tickPositions[i + 1] !== undefined ?
|
14080
|
-
|
15082
|
+
to = tickPositions[i + 1] !== undefined ?
|
15083
|
+
tickPositions[i + 1] + tickmarkOffset :
|
15084
|
+
axis.max - tickmarkOffset;
|
15085
|
+
|
15086
|
+
if (
|
15087
|
+
i % 2 === 0 &&
|
15088
|
+
pos < axis.max &&
|
15089
|
+
to <= axis.max + (
|
15090
|
+
chart.polar ?
|
15091
|
+
-tickmarkOffset :
|
15092
|
+
tickmarkOffset
|
15093
|
+
)
|
15094
|
+
) { // #2248, #4660
|
14081
15095
|
if (!alternateBands[pos]) {
|
14082
15096
|
alternateBands[pos] = new H.PlotLineOrBand(axis);
|
14083
15097
|
}
|
@@ -14095,9 +15109,12 @@
|
|
14095
15109
|
|
14096
15110
|
// custom plot lines and bands
|
14097
15111
|
if (!axis._addedPlotLB) { // only first time
|
14098
|
-
each(
|
14099
|
-
|
14100
|
-
|
15112
|
+
each(
|
15113
|
+
(options.plotLines || []).concat(options.plotBands || []),
|
15114
|
+
function(plotLineOptions) {
|
15115
|
+
axis.addPlotBandOrLine(plotLineOptions);
|
15116
|
+
}
|
15117
|
+
);
|
14101
15118
|
axis._addedPlotLB = true;
|
14102
15119
|
}
|
14103
15120
|
|
@@ -14111,9 +15128,13 @@
|
|
14111
15128
|
destroyInactiveItems = function() {
|
14112
15129
|
i = forDestruction.length;
|
14113
15130
|
while (i--) {
|
14114
|
-
// When resizing rapidly, the same items
|
15131
|
+
// When resizing rapidly, the same items
|
15132
|
+
// may be destroyed in different timeouts,
|
14115
15133
|
// or the may be reactivated
|
14116
|
-
if (
|
15134
|
+
if (
|
15135
|
+
coll[forDestruction[i]] &&
|
15136
|
+
!coll[forDestruction[i]].isActive
|
15137
|
+
) {
|
14117
15138
|
coll[forDestruction[i]].destroy();
|
14118
15139
|
delete coll[forDestruction[i]];
|
14119
15140
|
}
|
@@ -14133,7 +15154,11 @@
|
|
14133
15154
|
// When the objects are finished fading out, destroy them
|
14134
15155
|
syncTimeout(
|
14135
15156
|
destroyInactiveItems,
|
14136
|
-
coll === alternateBands ||
|
15157
|
+
coll === alternateBands ||
|
15158
|
+
!chart.hasRendered ||
|
15159
|
+
!delay ?
|
15160
|
+
0 :
|
15161
|
+
delay
|
14137
15162
|
);
|
14138
15163
|
});
|
14139
15164
|
|
@@ -14225,9 +15250,12 @@
|
|
14225
15250
|
});
|
14226
15251
|
|
14227
15252
|
// Destroy collections
|
14228
|
-
each(
|
14229
|
-
|
14230
|
-
|
15253
|
+
each(
|
15254
|
+
[axis.ticks, axis.minorTicks, axis.alternateBands],
|
15255
|
+
function(coll) {
|
15256
|
+
destroyObjectProperties(coll);
|
15257
|
+
}
|
15258
|
+
);
|
14231
15259
|
if (plotLinesAndBands) {
|
14232
15260
|
i = plotLinesAndBands.length;
|
14233
15261
|
while (i--) { // #1975
|
@@ -14236,15 +15264,21 @@
|
|
14236
15264
|
}
|
14237
15265
|
|
14238
15266
|
// Destroy local variables
|
14239
|
-
each(
|
14240
|
-
|
14241
|
-
|
15267
|
+
each(
|
15268
|
+
['stackTotalGroup', 'axisLine', 'axisTitle', 'axisGroup',
|
15269
|
+
'gridGroup', 'labelGroup', 'cross'
|
15270
|
+
],
|
15271
|
+
function(prop) {
|
15272
|
+
if (axis[prop]) {
|
15273
|
+
axis[prop] = axis[prop].destroy();
|
15274
|
+
}
|
14242
15275
|
}
|
14243
|
-
|
15276
|
+
);
|
14244
15277
|
|
14245
15278
|
// Destroy each generated group for plotlines and plotbands
|
14246
15279
|
for (plotGroup in axis.plotLinesAndBandsGroups) {
|
14247
|
-
axis.plotLinesAndBandsGroups[plotGroup] =
|
15280
|
+
axis.plotLinesAndBandsGroups[plotGroup] =
|
15281
|
+
axis.plotLinesAndBandsGroups[plotGroup].destroy();
|
14248
15282
|
}
|
14249
15283
|
|
14250
15284
|
// Delete all properties and fall back to the prototype.
|
@@ -14290,15 +15324,24 @@
|
|
14290
15324
|
|
14291
15325
|
// Get the path
|
14292
15326
|
if (!snap) {
|
14293
|
-
pos = e &&
|
15327
|
+
pos = e &&
|
15328
|
+
(
|
15329
|
+
this.horiz ?
|
15330
|
+
e.chartX - this.pos :
|
15331
|
+
this.len - e.chartY + this.pos
|
15332
|
+
);
|
14294
15333
|
} else if (defined(point)) {
|
14295
|
-
|
15334
|
+
// #3834
|
15335
|
+
pos = this.isXAxis ? point.plotX : this.len - point.plotY;
|
14296
15336
|
}
|
14297
15337
|
|
14298
15338
|
if (defined(pos)) {
|
14299
15339
|
path = this.getPlotLinePath(
|
14300
15340
|
// First argument, value, only used on radial
|
14301
|
-
point && (this.isXAxis ?
|
15341
|
+
point && (this.isXAxis ?
|
15342
|
+
point.x :
|
15343
|
+
pick(point.stackY, point.y)
|
15344
|
+
),
|
14302
15345
|
null,
|
14303
15346
|
null,
|
14304
15347
|
null,
|
@@ -14317,8 +15360,11 @@
|
|
14317
15360
|
if (!graphic) {
|
14318
15361
|
this.cross = graphic = this.chart.renderer
|
14319
15362
|
.path()
|
14320
|
-
.addClass(
|
14321
|
-
|
15363
|
+
.addClass(
|
15364
|
+
'highcharts-crosshair highcharts-crosshair-' +
|
15365
|
+
(categorized ? 'category ' : 'thin ') +
|
15366
|
+
options.className
|
15367
|
+
)
|
14322
15368
|
.attr({
|
14323
15369
|
zIndex: pick(options.zIndex, 2)
|
14324
15370
|
})
|
@@ -14327,7 +15373,13 @@
|
|
14327
15373
|
|
14328
15374
|
// Presentational attributes
|
14329
15375
|
graphic.attr({
|
14330
|
-
'stroke': options.color ||
|
15376
|
+
'stroke': options.color ||
|
15377
|
+
(
|
15378
|
+
categorized ?
|
15379
|
+
color('#ccd6eb')
|
15380
|
+
.setOpacity(0.25).get() :
|
15381
|
+
'#cccccc'
|
15382
|
+
),
|
14331
15383
|
'stroke-width': pick(options.width, 1)
|
14332
15384
|
}).css({
|
14333
15385
|
'pointer-events': 'none'
|
@@ -16086,7 +17138,6 @@
|
|
16086
17138
|
isObject = H.isObject,
|
16087
17139
|
offset = H.offset,
|
16088
17140
|
pick = H.pick,
|
16089
|
-
removeEvent = H.removeEvent,
|
16090
17141
|
splat = H.splat,
|
16091
17142
|
Tooltip = H.Tooltip;
|
16092
17143
|
|
@@ -16294,14 +17345,15 @@
|
|
16294
17345
|
getChartCoordinatesFromPoint: function(point, inverted) {
|
16295
17346
|
var series = point.series,
|
16296
17347
|
xAxis = series.xAxis,
|
16297
|
-
yAxis = series.yAxis
|
17348
|
+
yAxis = series.yAxis,
|
17349
|
+
plotX = pick(point.clientX, point.plotX);
|
16298
17350
|
|
16299
17351
|
if (xAxis && yAxis) {
|
16300
17352
|
return inverted ? {
|
16301
|
-
chartX: xAxis.len + xAxis.pos -
|
17353
|
+
chartX: xAxis.len + xAxis.pos - plotX,
|
16302
17354
|
chartY: yAxis.len + yAxis.pos - point.plotY
|
16303
17355
|
} : {
|
16304
|
-
chartX:
|
17356
|
+
chartX: plotX + xAxis.pos,
|
16305
17357
|
chartY: point.plotY + yAxis.pos
|
16306
17358
|
};
|
16307
17359
|
}
|
@@ -17007,9 +18059,13 @@
|
|
17007
18059
|
container.onclick = function(e) {
|
17008
18060
|
pointer.onContainerClick(e);
|
17009
18061
|
};
|
17010
|
-
addEvent(
|
17011
|
-
|
17012
|
-
|
18062
|
+
this.unbindContainerMouseLeave = addEvent(
|
18063
|
+
container,
|
18064
|
+
'mouseleave',
|
18065
|
+
pointer.onContainerMouseLeave
|
18066
|
+
);
|
18067
|
+
if (!H.unbindDocumentMouseUp) {
|
18068
|
+
H.unbindDocumentMouseUp = addEvent(
|
17013
18069
|
ownerDoc,
|
17014
18070
|
'mouseup',
|
17015
18071
|
pointer.onDocumentMouseUp
|
@@ -17022,8 +18078,8 @@
|
|
17022
18078
|
container.ontouchmove = function(e) {
|
17023
18079
|
pointer.onContainerTouchMove(e);
|
17024
18080
|
};
|
17025
|
-
if (H.
|
17026
|
-
addEvent(
|
18081
|
+
if (!H.unbindDocumentTouchEnd) {
|
18082
|
+
H.unbindDocumentTouchEnd = addEvent(
|
17027
18083
|
ownerDoc,
|
17028
18084
|
'touchend',
|
17029
18085
|
pointer.onDocumentTouchEnd
|
@@ -17037,22 +18093,20 @@
|
|
17037
18093
|
* Destroys the Pointer object and disconnects DOM events.
|
17038
18094
|
*/
|
17039
18095
|
destroy: function() {
|
17040
|
-
var pointer = this
|
17041
|
-
ownerDoc = this.chart.container.ownerDocument;
|
18096
|
+
var pointer = this;
|
17042
18097
|
|
17043
18098
|
if (pointer.unDocMouseMove) {
|
17044
18099
|
pointer.unDocMouseMove();
|
17045
18100
|
}
|
17046
18101
|
|
17047
|
-
|
17048
|
-
|
17049
|
-
'mouseleave',
|
17050
|
-
pointer.onContainerMouseLeave
|
17051
|
-
);
|
18102
|
+
this.unbindContainerMouseLeave();
|
18103
|
+
|
17052
18104
|
if (!H.chartCount) {
|
17053
|
-
|
17054
|
-
|
17055
|
-
|
18105
|
+
if (H.unbindDocumentMouseUp) {
|
18106
|
+
H.unbindDocumentMouseUp = H.unbindDocumentMouseUp();
|
18107
|
+
}
|
18108
|
+
if (H.unbindDocumentTouchEnd) {
|
18109
|
+
H.unbindDocumentTouchEnd = H.unbindDocumentTouchEnd();
|
17056
18110
|
}
|
17057
18111
|
}
|
17058
18112
|
|
@@ -17764,7 +18818,7 @@
|
|
17764
18818
|
*
|
17765
18819
|
* @private
|
17766
18820
|
*/
|
17767
|
-
positionCheckboxes: function(
|
18821
|
+
positionCheckboxes: function() {
|
17768
18822
|
var alignAttr = this.group && this.group.alignAttr,
|
17769
18823
|
translateY,
|
17770
18824
|
clipHeight = this.clipHeight || this.legendHeight,
|
@@ -17778,7 +18832,7 @@
|
|
17778
18832
|
|
17779
18833
|
if (checkbox) {
|
17780
18834
|
top = translateY + titleHeight + checkbox.y +
|
17781
|
-
(scrollOffset || 0) + 3;
|
18835
|
+
(this.scrollOffset || 0) + 3;
|
17782
18836
|
css(checkbox, {
|
17783
18837
|
left: (alignAttr.translateX + item.checkboxOffset +
|
17784
18838
|
checkbox.x - 20) + 'px',
|
@@ -17787,7 +18841,7 @@
|
|
17787
18841
|
clipHeight - 6 ? '' : 'none'
|
17788
18842
|
});
|
17789
18843
|
}
|
17790
|
-
});
|
18844
|
+
}, this);
|
17791
18845
|
}
|
17792
18846
|
},
|
17793
18847
|
|
@@ -18425,8 +19479,7 @@
|
|
18425
19479
|
clipHeight = this.clipHeight,
|
18426
19480
|
navOptions = this.options.navigation,
|
18427
19481
|
pager = this.pager,
|
18428
|
-
padding = this.padding
|
18429
|
-
scrollOffset;
|
19482
|
+
padding = this.padding;
|
18430
19483
|
|
18431
19484
|
// When resizing while looking at the last page
|
18432
19485
|
if (currentPage > pageCount) {
|
@@ -18476,14 +19529,14 @@
|
|
18476
19529
|
});
|
18477
19530
|
|
18478
19531
|
|
18479
|
-
scrollOffset = -pages[currentPage - 1] + this.initialItemY;
|
19532
|
+
this.scrollOffset = -pages[currentPage - 1] + this.initialItemY;
|
18480
19533
|
|
18481
19534
|
this.scrollGroup.animate({
|
18482
|
-
translateY: scrollOffset
|
19535
|
+
translateY: this.scrollOffset
|
18483
19536
|
});
|
18484
19537
|
|
18485
19538
|
this.currentPage = currentPage;
|
18486
|
-
this.positionCheckboxes(
|
19539
|
+
this.positionCheckboxes();
|
18487
19540
|
}
|
18488
19541
|
|
18489
19542
|
}
|
@@ -20323,7 +21376,9 @@
|
|
20323
21376
|
|
20324
21377
|
// Record preliminary dimensions for later comparison
|
20325
21378
|
tempWidth = chart.plotWidth;
|
20326
|
-
|
21379
|
+
// 21 is the most common correction for X axis labels
|
21380
|
+
// use Math.max to prevent negative plotHeight
|
21381
|
+
tempHeight = chart.plotHeight = Math.max(chart.plotHeight - 21, 0);
|
20327
21382
|
|
20328
21383
|
// Get margins by pre-rendering axes
|
20329
21384
|
each(axes, function(axis) {
|
@@ -22907,6 +23962,55 @@
|
|
22907
23962
|
* @since 2.3.5
|
22908
23963
|
* @apioption plotOptions.series.dataLabels.zIndex
|
22909
23964
|
*/
|
23965
|
+
|
23966
|
+
/**
|
23967
|
+
* A declarative filter for which data labels to display. The
|
23968
|
+
* declarative filter is designed for use when callback functions are
|
23969
|
+
* not available, like when the chart options require a pure JSON
|
23970
|
+
* structure or for use with graphical editors. For programmatic
|
23971
|
+
* control, use the `formatter` instead, and return `false` to disable
|
23972
|
+
* a single data label.
|
23973
|
+
*
|
23974
|
+
* @example
|
23975
|
+
* filter: {
|
23976
|
+
* property: 'percentage',
|
23977
|
+
* operator: '>',
|
23978
|
+
* value: 4
|
23979
|
+
* }
|
23980
|
+
*
|
23981
|
+
* @sample highcharts/demo/pie-monochrome
|
23982
|
+
* Data labels filtered by percentage
|
23983
|
+
*
|
23984
|
+
* @type {Object}
|
23985
|
+
* @since 6.0.3
|
23986
|
+
* @apioption plotOptions.series.dataLabels.filter
|
23987
|
+
*/
|
23988
|
+
|
23989
|
+
/**
|
23990
|
+
* The point property to filter by. Point options are passed directly to
|
23991
|
+
* properties, additionally there are `y` value, `percentage` and others
|
23992
|
+
* listed under [Point](https://api.highcharts.com/class-reference/Highcharts.Point)
|
23993
|
+
* members.
|
23994
|
+
*
|
23995
|
+
* @type {String}
|
23996
|
+
* @apioption plotOptions.series.dataLabels.filter.property
|
23997
|
+
*/
|
23998
|
+
|
23999
|
+
/**
|
24000
|
+
* The operator to compare by. Can be one of `>`, `<`, `>=`, `<=`, `==`,
|
24001
|
+
* and `===`.
|
24002
|
+
*
|
24003
|
+
* @type {String}
|
24004
|
+
* @validvalue [">", "<", ">=", "<=", "==", "===""]
|
24005
|
+
* @apioption plotOptions.series.dataLabels.filter.operator
|
24006
|
+
*/
|
24007
|
+
|
24008
|
+
/**
|
24009
|
+
* The value to compare against.
|
24010
|
+
*
|
24011
|
+
* @type {Mixed}
|
24012
|
+
* @apioption plotOptions.series.dataLabels.filter.value
|
24013
|
+
*/
|
22910
24014
|
},
|
22911
24015
|
// draw points outside the plot area when the number of points is less than
|
22912
24016
|
// this
|
@@ -23978,6 +25082,7 @@
|
|
23978
25082
|
xExtremes,
|
23979
25083
|
val2lin = xAxis && xAxis.val2lin,
|
23980
25084
|
isLog = xAxis && xAxis.isLog,
|
25085
|
+
throwOnUnsorted = series.requireSorting,
|
23981
25086
|
min,
|
23982
25087
|
max;
|
23983
25088
|
|
@@ -24054,8 +25159,9 @@
|
|
24054
25159
|
// Unsorted data is not supported by the line tooltip, as well as
|
24055
25160
|
// data grouping and navigation in Stock charts (#725) and width
|
24056
25161
|
// calculation of columns (#1900)
|
24057
|
-
} else if (distance < 0 &&
|
25162
|
+
} else if (distance < 0 && throwOnUnsorted) {
|
24058
25163
|
H.error(15);
|
25164
|
+
throwOnUnsorted = false; // Only once
|
24059
25165
|
}
|
24060
25166
|
}
|
24061
25167
|
|
@@ -24650,7 +25756,6 @@
|
|
24650
25756
|
var series = this,
|
24651
25757
|
points = series.points,
|
24652
25758
|
chart = series.chart,
|
24653
|
-
plotY,
|
24654
25759
|
i,
|
24655
25760
|
point,
|
24656
25761
|
symbol,
|
@@ -24675,7 +25780,6 @@
|
|
24675
25780
|
|
24676
25781
|
for (i = 0; i < points.length; i++) {
|
24677
25782
|
point = points[i];
|
24678
|
-
plotY = point.plotY;
|
24679
25783
|
graphic = point.graphic;
|
24680
25784
|
pointMarkerOptions = point.marker || {};
|
24681
25785
|
hasPointMarker = !!point.marker;
|
@@ -24683,7 +25787,7 @@
|
|
24683
25787
|
isInside = point.isInside;
|
24684
25788
|
|
24685
25789
|
// only draw the point if y is defined
|
24686
|
-
if (enabled &&
|
25790
|
+
if (enabled && !point.isNull) {
|
24687
25791
|
|
24688
25792
|
// Shortcuts
|
24689
25793
|
symbol = pick(pointMarkerOptions.symbol, series.symbol);
|
@@ -25093,7 +26197,9 @@
|
|
25093
26197
|
attribs;
|
25094
26198
|
|
25095
26199
|
if (graph) {
|
25096
|
-
graph.endX =
|
26200
|
+
graph.endX = series.preventGraphAnimation ?
|
26201
|
+
null :
|
26202
|
+
graphPath.xMap;
|
25097
26203
|
graph.animate({
|
25098
26204
|
d: graphPath
|
25099
26205
|
});
|
@@ -27258,9 +28364,6 @@
|
|
27258
28364
|
) {
|
27259
28365
|
preserveGroups.length = 0;
|
27260
28366
|
}
|
27261
|
-
if (series.options.isInternal) {
|
27262
|
-
preserve.length = 0;
|
27263
|
-
}
|
27264
28367
|
|
27265
28368
|
// Make sure preserved properties are not destroyed (#3094)
|
27266
28369
|
preserve = preserveGroups.concat(preserve);
|
@@ -27558,8 +28661,13 @@
|
|
27558
28661
|
points = points || this.points;
|
27559
28662
|
|
27560
28663
|
if (this.options.stacking) {
|
27561
|
-
|
28664
|
+
|
27562
28665
|
for (i = 0; i < points.length; i++) {
|
28666
|
+
// Reset after point update (#7326)
|
28667
|
+
points[i].leftNull = points[i].rightNull = null;
|
28668
|
+
|
28669
|
+
// Create a map where we can quickly look up the points by their
|
28670
|
+
// X values.
|
27563
28671
|
pointMap[points[i].x] = points[i];
|
27564
28672
|
}
|
27565
28673
|
|
@@ -27810,7 +28918,7 @@
|
|
27810
28918
|
|
27811
28919
|
// Create or update the area
|
27812
28920
|
if (area) { // update
|
27813
|
-
area.endX = areaPath.xMap;
|
28921
|
+
area.endX = series.preventGraphAnimation ? null : areaPath.xMap;
|
27814
28922
|
area.animate({
|
27815
28923
|
d: areaPath
|
27816
28924
|
});
|
@@ -28549,17 +29657,15 @@
|
|
28549
29657
|
* @default 0.1
|
28550
29658
|
* @product highcharts highstock
|
28551
29659
|
*/
|
28552
|
-
brightness: 0.1
|
29660
|
+
brightness: 0.1
|
28553
29661
|
|
28554
|
-
shadow: false
|
28555
29662
|
|
28556
29663
|
},
|
28557
29664
|
|
28558
29665
|
|
28559
29666
|
select: {
|
28560
29667
|
color: '#cccccc',
|
28561
|
-
borderColor: '#000000'
|
28562
|
-
shadow: false
|
29668
|
+
borderColor: '#000000'
|
28563
29669
|
}
|
28564
29670
|
|
28565
29671
|
},
|
@@ -28854,7 +29960,11 @@
|
|
28854
29960
|
|
28855
29961
|
// Reverse zeros if there's no positive value in the series
|
28856
29962
|
// in visible range (#7046)
|
28857
|
-
if (
|
29963
|
+
if (
|
29964
|
+
point.y === threshold &&
|
29965
|
+
series.dataMax <= threshold &&
|
29966
|
+
yAxis.min < threshold // and if there's room for it (#7311)
|
29967
|
+
) {
|
28858
29968
|
up = !up;
|
28859
29969
|
}
|
28860
29970
|
|
@@ -29116,7 +30226,7 @@
|
|
29116
30226
|
*
|
29117
30227
|
* @type {Object}
|
29118
30228
|
* @extends series,plotOptions.column
|
29119
|
-
* @excluding dataParser,dataURL
|
30229
|
+
* @excluding dataParser,dataURL,marker
|
29120
30230
|
* @product highcharts highstock
|
29121
30231
|
* @apioption series.column
|
29122
30232
|
*/
|
@@ -30494,7 +31604,7 @@
|
|
30494
31604
|
|
30495
31605
|
/* eslint max-len: ["warn", 80, 4] */
|
30496
31606
|
/**
|
30497
|
-
*
|
31607
|
+
* General distribution algorithm for distributing labels of differing size
|
30498
31608
|
* along a confined length in two dimensions. The algorithm takes an array of
|
30499
31609
|
* objects containing a size, a target and a rank. It will place the labels as
|
30500
31610
|
* close as possible to their targets, skipping the lowest ranked labels if
|
@@ -30544,7 +31654,8 @@
|
|
30544
31654
|
boxes = map(boxes, function(box) {
|
30545
31655
|
return {
|
30546
31656
|
size: box.size,
|
30547
|
-
targets: [box.target]
|
31657
|
+
targets: [box.target],
|
31658
|
+
align: pick(box.align, 0.5)
|
30548
31659
|
};
|
30549
31660
|
});
|
30550
31661
|
|
@@ -30554,10 +31665,12 @@
|
|
30554
31665
|
while (i--) {
|
30555
31666
|
box = boxes[i];
|
30556
31667
|
// Composite box, average of targets
|
30557
|
-
target = (
|
30558
|
-
Math.
|
31668
|
+
target = (
|
31669
|
+
Math.min.apply(0, box.targets) +
|
31670
|
+
Math.max.apply(0, box.targets)
|
31671
|
+
) / 2;
|
30559
31672
|
box.pos = Math.min(
|
30560
|
-
Math.max(0, target - box.size
|
31673
|
+
Math.max(0, target - box.size * box.align),
|
30561
31674
|
len - box.size
|
30562
31675
|
);
|
30563
31676
|
}
|
@@ -30573,6 +31686,7 @@
|
|
30573
31686
|
boxes[i - 1].targets = boxes[i - 1]
|
30574
31687
|
.targets
|
30575
31688
|
.concat(boxes[i].targets);
|
31689
|
+
boxes[i - 1].align = 0.5;
|
30576
31690
|
|
30577
31691
|
// Overlapping right, push left
|
30578
31692
|
if (boxes[i - 1].pos + boxes[i - 1].size > len) {
|
@@ -30618,6 +31732,33 @@
|
|
30618
31732
|
defer = pick(options.defer, !!seriesOptions.animation),
|
30619
31733
|
renderer = series.chart.renderer;
|
30620
31734
|
|
31735
|
+
/*
|
31736
|
+
* Handle the dataLabels.filter option.
|
31737
|
+
*/
|
31738
|
+
function applyFilter(point, options) {
|
31739
|
+
var filter = options.filter,
|
31740
|
+
op,
|
31741
|
+
prop,
|
31742
|
+
val;
|
31743
|
+
if (filter) {
|
31744
|
+
op = filter.operator;
|
31745
|
+
prop = point[filter.property];
|
31746
|
+
val = filter.value;
|
31747
|
+
if (
|
31748
|
+
(op === '>' && prop > val) ||
|
31749
|
+
(op === '<' && prop < val) ||
|
31750
|
+
(op === '>=' && prop >= val) ||
|
31751
|
+
(op === '<=' && prop <= val) ||
|
31752
|
+
(op === '==' && prop == val) || // eslint-disable-line eqeqeq
|
31753
|
+
(op === '===' && prop === val)
|
31754
|
+
) {
|
31755
|
+
return true;
|
31756
|
+
}
|
31757
|
+
return false;
|
31758
|
+
}
|
31759
|
+
return true;
|
31760
|
+
}
|
31761
|
+
|
30621
31762
|
if (options.enabled || series._hasPointLabels) {
|
30622
31763
|
|
30623
31764
|
// Process default alignment of data labels for columns
|
@@ -30676,6 +31817,10 @@
|
|
30676
31817
|
generalOptions.enabled
|
30677
31818
|
) && !point.isNull; // #2282, #4641, #7112
|
30678
31819
|
|
31820
|
+
if (enabled) {
|
31821
|
+
enabled = applyFilter(point, pointOptions || options) === true;
|
31822
|
+
}
|
31823
|
+
|
30679
31824
|
if (enabled) {
|
30680
31825
|
// Create individual options structure that can be extended
|
30681
31826
|
// without affecting others
|
@@ -30798,7 +31943,7 @@
|
|
30798
31943
|
) {
|
30799
31944
|
var chart = this.chart,
|
30800
31945
|
inverted = chart.inverted,
|
30801
|
-
plotX = pick(point.plotX, -9999),
|
31946
|
+
plotX = pick(point.dlBox && point.dlBox.centerX, point.plotX, -9999),
|
30802
31947
|
plotY = pick(point.plotY, -9999),
|
30803
31948
|
bBox = dataLabel.getBBox(),
|
30804
31949
|
fontSize,
|
@@ -31545,57 +32690,51 @@
|
|
31545
32690
|
// Collect potensial overlapping data labels. Stack labels probably don't need
|
31546
32691
|
// to be considered because they are usually accompanied by data labels that lie
|
31547
32692
|
// inside the columns.
|
31548
|
-
Chart.prototype
|
31549
|
-
|
31550
|
-
var labels = [];
|
32693
|
+
addEvent(Chart.prototype, 'render', function collectAndHide() {
|
32694
|
+
var labels = [];
|
31551
32695
|
|
31552
|
-
|
31553
|
-
|
31554
|
-
|
31555
|
-
|
32696
|
+
// Consider external label collectors
|
32697
|
+
each(this.labelCollectors || [], function(collector) {
|
32698
|
+
labels = labels.concat(collector());
|
32699
|
+
});
|
31556
32700
|
|
31557
|
-
|
31558
|
-
|
31559
|
-
|
31560
|
-
|
31561
|
-
|
31562
|
-
|
31563
|
-
|
31564
|
-
|
31565
|
-
});
|
32701
|
+
each(this.yAxis || [], function(yAxis) {
|
32702
|
+
if (
|
32703
|
+
yAxis.options.stackLabels &&
|
32704
|
+
!yAxis.options.stackLabels.allowOverlap
|
32705
|
+
) {
|
32706
|
+
objectEach(yAxis.stacks, function(stack) {
|
32707
|
+
objectEach(stack, function(stackItem) {
|
32708
|
+
labels.push(stackItem.label);
|
31566
32709
|
});
|
31567
|
-
}
|
31568
|
-
}
|
32710
|
+
});
|
32711
|
+
}
|
32712
|
+
});
|
31569
32713
|
|
31570
|
-
|
31571
|
-
|
31572
|
-
|
31573
|
-
|
32714
|
+
each(this.series || [], function(series) {
|
32715
|
+
var dlOptions = series.options.dataLabels,
|
32716
|
+
// Range series have two collections
|
32717
|
+
collections = series.dataLabelCollections || ['dataLabel'];
|
31574
32718
|
|
31575
|
-
|
31576
|
-
|
31577
|
-
|
31578
|
-
|
31579
|
-
|
31580
|
-
|
31581
|
-
|
31582
|
-
|
31583
|
-
|
31584
|
-
|
31585
|
-
|
31586
|
-
|
31587
|
-
|
31588
|
-
|
31589
|
-
});
|
32719
|
+
if (
|
32720
|
+
(dlOptions.enabled || series._hasPointLabels) &&
|
32721
|
+
!dlOptions.allowOverlap &&
|
32722
|
+
series.visible
|
32723
|
+
) { // #3866
|
32724
|
+
each(collections, function(coll) {
|
32725
|
+
each(series.points, function(point) {
|
32726
|
+
if (point[coll]) {
|
32727
|
+
point[coll].labelrank = pick(
|
32728
|
+
point.labelrank,
|
32729
|
+
point.shapeArgs && point.shapeArgs.height
|
32730
|
+
); // #4118
|
32731
|
+
labels.push(point[coll]);
|
32732
|
+
}
|
31590
32733
|
});
|
31591
|
-
}
|
31592
|
-
}
|
31593
|
-
|
31594
|
-
|
31595
|
-
|
31596
|
-
// Do it on render and after each chart redraw
|
31597
|
-
addEvent(chart, 'render', collectAndHide);
|
31598
|
-
|
32734
|
+
});
|
32735
|
+
}
|
32736
|
+
});
|
32737
|
+
this.hideOverlappingLabels(labels);
|
31599
32738
|
});
|
31600
32739
|
|
31601
32740
|
/**
|
@@ -32715,9 +33854,7 @@
|
|
32715
33854
|
chart.redraw();
|
32716
33855
|
}
|
32717
33856
|
|
32718
|
-
fireEvent(series, showOrHide
|
32719
|
-
redraw: redraw
|
32720
|
-
});
|
33857
|
+
fireEvent(series, showOrHide);
|
32721
33858
|
},
|
32722
33859
|
|
32723
33860
|
/**
|
@@ -32983,13 +34120,13 @@
|
|
32983
34120
|
var i;
|
32984
34121
|
H.objectEach(options, function(val, key) {
|
32985
34122
|
if (!depth && inArray(key, ['series', 'xAxis', 'yAxis']) > -1) {
|
32986
|
-
|
34123
|
+
val = splat(val);
|
32987
34124
|
|
32988
34125
|
ret[key] = [];
|
32989
34126
|
|
32990
34127
|
// Iterate over collections like series, xAxis or yAxis and map
|
32991
34128
|
// the items by index.
|
32992
|
-
for (i = 0; i <
|
34129
|
+
for (i = 0; i < val.length; i++) {
|
32993
34130
|
if (curr[key][i]) { // Item exists in current data (#6347)
|
32994
34131
|
ret[key][i] = {};
|
32995
34132
|
getCurrent(
|