Aggrid custom
This commit is contained in:
21
node_modules/ag-charts-core/LICENSE.txt
generated
vendored
Executable file
21
node_modules/ag-charts-core/LICENSE.txt
generated
vendored
Executable file
@@ -0,0 +1,21 @@
|
||||
The MIT License
|
||||
|
||||
Copyright (c) 2015-2026 AG GRID LTD
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
337
node_modules/ag-charts-core/README.md
generated
vendored
Executable file
337
node_modules/ag-charts-core/README.md
generated
vendored
Executable file
@@ -0,0 +1,337 @@
|
||||
# Core Charting Library
|
||||
|
||||
<div align="center">
|
||||
<picture>
|
||||
<source media="(prefers-color-scheme: dark)" srcset="https://github.com/ag-grid/ag-grid/blob/latest/documentation/ag-grid-docs/public/images/ag-logos/svg-logos/AG-Charts-Logo_Dark-Theme.svg?raw=true"/>
|
||||
<source media="(prefers-color-scheme: light)" srcset="https://github.com/ag-grid/ag-grid/blob/latest/documentation/ag-grid-docs/public/images/ag-logos/svg-logos/AG-Charts-Logo_Light-Theme.svg?raw=true"/>
|
||||
<img width="100%" alt="AG Charts Logo" src="https://github.com/ag-grid/ag-grid/blob/latest/documentation/ag-grid-docs/public/images/ag-logos/svg-logos/AG-Charts-Logo_Light-Theme.svg?raw=true"/>
|
||||
</picture>
|
||||
<div align="center">
|
||||
<h4><a href="https://www.ag-grid.com/charts/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github">🌐 Website</a> • <a href="https://www.ag-grid.com/charts/core/quick-start/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github">📖 Documentation</a> • <a href="https://www.ag-grid.com/charts/gallery/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github">📊 Gallery</a></h4>
|
||||
</div>
|
||||
<br>
|
||||
<a href="https://github.com/ag-grid/ag-charts/releases">
|
||||
<img src="https://img.shields.io/github/v/release/ag-grid/ag-charts?style=for-the-badge" alt="GitHub Release">
|
||||
</a>
|
||||
<a href="https://www.npmjs.com/package/ag-charts-core">
|
||||
<img src="https://img.shields.io/npm/dm/ag-charts-core?style=for-the-badge" alt="NPM Downloads">
|
||||
</a>
|
||||
<a href="https://github.com/ag-grid/ag-charts">
|
||||
<img src="https://img.shields.io/github/stars/ag-grid/ag-charts?style=for-the-badge" alt="GitHub Repo stars">
|
||||
</a>
|
||||
<a href="https://github.com/ag-grid/ag-charts">
|
||||
<img alt="GitHub forks" src="https://img.shields.io/github/forks/ag-grid/ag-charts?style=for-the-badge">
|
||||
</a>
|
||||
<br><br>
|
||||
<a href="https://sonarcloud.io/dashboard?id=ag-charts-community">
|
||||
<img src="https://sonarcloud.io/api/project_badges/measure?project=ag-charts-community&metric=alert_status" alt="Quality Gate Status">
|
||||
</a>
|
||||
<a href="https://npm.io/package/ag-charts-core">
|
||||
<img src="https://img.shields.io/npms-io/maintenance-score/ag-grid-community" alt="npms.io Maintenance Score">
|
||||
</a>
|
||||
<a href="https://github.com/ag-grid/ag-charts/graphs/commit-activity">
|
||||
<img src="https://img.shields.io/github/commit-activity/m/ag-grid/ag-charts" alt="GitHub commit activity">
|
||||
</a>
|
||||
<a href="https://github.com/ag-grid/ag-charts/network/dependents">
|
||||
<img src="https://img.shields.io/librariesio/dependents/npm/ag-charts-core" alt="Dependents (via libraries.io?style=for-the-badge)">
|
||||
</a>
|
||||
<br><br>
|
||||
<!-- START MAIN DESCRIPTION -->
|
||||
<p>AG Charts is a <strong>fully-featured</strong> and <strong>highly customizable</strong> canvas-based Core Charting library. It delivers <strong>outstanding performance</strong> and has <strong>no third-party dependencies</strong>.</p>
|
||||
<!-- END MAIN DESCRIPTION -->
|
||||
<br>
|
||||
</div>
|
||||
|
||||
<picture>
|
||||
<source media="(prefers-color-scheme: dark)" srcset="https://github.com/ag-grid/ag-charts/blob/latest/packages/ag-charts-website/public/images/readme-assets/gallery-dark.gif?raw=true"/>
|
||||
<source media="(prefers-color-scheme: light)" srcset="https://github.com/ag-grid/ag-charts/blob/latest/packages/ag-charts-website/public/images/readme-assets/gallery.gif?raw=true"/>
|
||||
<img width="100%" alt="Preview of AG Charts Core Charting Examples" src="https://github.com/ag-grid/ag-charts/blob/latest/packages/ag-charts-website/public/images/readme-assets/gallery.gif?raw=true"/>
|
||||
</picture>
|
||||
<div align="right">
|
||||
<a href="https://www.ag-grid.com/charts/gallery/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github"><br><img alt="Static Badge" src="https://img.shields.io/badge/View%20Gallery-blue?style=for-the-badge&logo=data%3Aimage%2Fsvg%2Bxml%3Bbase64%2CPCFET0NUWVBFIHN2ZyBQVUJMSUMgIi0vL1czQy8vRFREIFNWRyAxLjEvL0VOIiAiaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEuZHRkIj4KDTwhLS0gVXBsb2FkZWQgdG86IFNWRyBSZXBvLCB3d3cuc3ZncmVwby5jb20sIFRyYW5zZm9ybWVkIGJ5OiBTVkcgUmVwbyBNaXhlciBUb29scyAtLT4KPHN2ZyB3aWR0aD0iODAwcHgiIGhlaWdodD0iODAwcHgiIHZpZXdCb3g9IjAgMCAyNCAyNCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KDTxnIGlkPSJTVkdSZXBvX2JnQ2FycmllciIgc3Ryb2tlLXdpZHRoPSIwIi8%2BCg08ZyBpZD0iU1ZHUmVwb190cmFjZXJDYXJyaWVyIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4KDTxnIGlkPSJTVkdSZXBvX2ljb25DYXJyaWVyIj4gPHBhdGggZD0iTTE4IDIwLjc1SDZDNS4yNzA2NSAyMC43NSA0LjU3MTE4IDIwLjQ2MDMgNC4wNTU0NiAxOS45NDQ1QzMuNTM5NzMgMTkuNDI4OCAzLjI1IDE4LjcyOTMgMy4yNSAxOFY2QzMuMjUgNS4yNzA2NSAzLjUzOTczIDQuNTcxMTggNC4wNTU0NiA0LjA1NTQ2QzQuNTcxMTggMy41Mzk3MyA1LjI3MDY1IDMuMjUgNiAzLjI1SDEyQzEyLjE5ODkgMy4yNSAxMi4zODk3IDMuMzI5MDIgMTIuNTMwMyAzLjQ2OTY3QzEyLjY3MSAzLjYxMDMyIDEyLjc1IDMuODAxMDkgMTIuNzUgNEMxMi43NSA0LjE5ODkxIDEyLjY3MSA0LjM4OTY4IDEyLjUzMDMgNC41MzAzM0MxMi4zODk3IDQuNjcwOTggMTIuMTk4OSA0Ljc1IDEyIDQuNzVINkM1LjY2ODQ4IDQuNzUgNS4zNTA1NCA0Ljg4MTcgNS4xMTYxMiA1LjExNjEyQzQuODgxNyA1LjM1MDU0IDQuNzUgNS42Njg0OCA0Ljc1IDZWMThDNC43NSAxOC4zMzE1IDQuODgxNyAxOC42NDk1IDUuMTE2MTIgMTguODgzOUM1LjM1MDU0IDE5LjExODMgNS42Njg0OCAxOS4yNSA2IDE5LjI1SDE4QzE4LjMzMTUgMTkuMjUgMTguNjQ5NSAxOS4xMTgzIDE4Ljg4MzkgMTguODgzOUMxOS4xMTgzIDE4LjY0OTUgMTkuMjUgMTguMzMxNSAxOS4yNSAxOFYxMkMxOS4yNSAxMS44MDExIDE5LjMyOSAxMS42MTAzIDE5LjQ2OTcgMTEuNDY5N0MxOS42MTAzIDExLjMyOSAxOS44MDExIDExLjI1IDIwIDExLjI1QzIwLjE5ODkgMTEuMjUgMjAuMzg5NyAxMS4zMjkgMjAuNTMwMyAxMS40Njk3QzIwLjY3MSAxMS42MTAzIDIwLjc1IDExLjgwMTEgMjAuNzUgMTJWMThDMjAuNzUgMTguNzI5MyAyMC40NjAzIDE5LjQyODggMTkuOTQ0NSAxOS45NDQ1QzE5LjQyODggMjAuNDYwMyAxOC43MjkzIDIwLjc1IDE4IDIwLjc1WiIgZmlsbD0iI2ZmZmZmZiIvPiA8cGF0aCBkPSJNMjAgOC43NUMxOS44MDE5IDguNzQ3NDEgMTkuNjEyNiA4LjY2NzU2IDE5LjQ3MjUgOC41Mjc0N0MxOS4zMzI0IDguMzg3MzcgMTkuMjUyNiA4LjE5ODExIDE5LjI1IDhWNC43NUgxNkMxNS44MDExIDQuNzUgMTUuNjEwMyA0LjY3MDk4IDE1LjQ2OTcgNC41MzAzM0MxNS4zMjkgNC4zODk2OCAxNS4yNSA0LjE5ODkxIDE1LjI1IDRDMTUuMjUgMy44MDEwOSAxNS4zMjkgMy42MTAzMiAxNS40Njk3IDMuNDY5NjdDMTUuNjEwMyAzLjMyOTAyIDE1LjgwMTEgMy4yNSAxNiAzLjI1SDIwQzIwLjE5ODEgMy4yNTI1OSAyMC4zODc0IDMuMzMyNDQgMjAuNTI3NSAzLjQ3MjUzQzIwLjY2NzYgMy42MTI2MyAyMC43NDc0IDMuODAxODkgMjAuNzUgNFY4QzIwLjc0NzQgOC4xOTgxMSAyMC42Njc2IDguMzg3MzcgMjAuNTI3NSA4LjUyNzQ3QzIwLjM4NzQgOC42Njc1NiAyMC4xOTgxIDguNzQ3NDEgMjAgOC43NVoiIGZpbGw9IiNmZmZmZmYiLz4gPHBhdGggZD0iTTEzLjUgMTEuMjVDMTMuMzA3MSAxMS4yMzUyIDEzLjEyNzYgMTEuMTQ1NSAxMyAxMUMxMi44NzcgMTAuODYyNSAxMi44MDkgMTAuNjg0NSAxMi44MDkgMTAuNUMxMi44MDkgMTAuMzE1NSAxMi44NzcgMTAuMTM3NSAxMyAxMEwxOS41IDMuNUMxOS41Njg3IDMuNDI2MzEgMTkuNjUxNSAzLjM2NzIxIDE5Ljc0MzUgMy4zMjYyMkMxOS44MzU1IDMuMjg1MjMgMTkuOTM0OCAzLjI2MzE5IDIwLjAzNTUgMy4yNjE0MUMyMC4xMzYyIDMuMjU5NjMgMjAuMjM2MiAzLjI3ODE2IDIwLjMyOTYgMy4zMTU4OEMyMC40MjMgMy4zNTM2IDIwLjUwNzggMy40MDk3NCAyMC41NzkgMy40ODA5NkMyMC42NTAzIDMuNTUyMTggMjAuNzA2NCAzLjYzNzAxIDIwLjc0NDEgMy43MzA0QzIwLjc4MTggMy44MjM3OSAyMC44MDA0IDMuOTIzODIgMjAuNzk4NiA0LjAyNDUyQzIwLjc5NjggNC4xMjUyMyAyMC43NzQ4IDQuMjI0NTQgMjAuNzMzOCA0LjMxNjU0QzIwLjY5MjggNC40MDg1NCAyMC42MzM3IDQuNDkxMzQgMjAuNTYgNC41NkwxNCAxMUMxMy44NzI0IDExLjE0NTUgMTMuNjkyOSAxMS4yMzUyIDEzLjUgMTEuMjVaIiBmaWxsPSIjZmZmZmZmIi8%2BIDwvZz4KDTwvc3ZnPg%3D%3D">
|
||||
</a>
|
||||
</div>
|
||||
|
||||
## 📖 Overview
|
||||
|
||||
<details>
|
||||
<summary><strong>Table of Contents</strong></summary>
|
||||
|
||||
- [📖 Overview](#-overview)
|
||||
- [Chart Types](#chart-types)
|
||||
- [Features](#features)
|
||||
- [Financial Charts](#financial-charts)
|
||||
- [Map Charts](#map-charts)
|
||||
- [⚡️ Quick Start](#️-quick-start)
|
||||
- [Installation](#installation)
|
||||
- [Setup](#setup)
|
||||
- [🤝 Support](#-support)
|
||||
- [Enterprise Support](#enterprise-support)
|
||||
- [Bug Reports](#bug-reports)
|
||||
- [Questions](#questions)
|
||||
- [Contributing](#contributing)
|
||||
- [⚠️ License](#️-license)
|
||||
|
||||
</details>
|
||||
|
||||
AG Charts is available in two versions: Community & Enterprise.
|
||||
|
||||
- `ag-charts-community` is free, available under the MIT license, and comes with core series types, such as [Pie](https://www.ag-grid.com/charts/core/pie-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github), [Area](https://www.ag-grid.com/charts/core/area-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github), [Bar](https://www.ag-grid.com/charts/core/bar-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github), [Scatter](https://www.ag-grid.com/charts/core/scatter-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) and [Bubble](https://www.ag-grid.com/charts/core/bubble-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) in addition to all of the key features expected from a Core charting library, including [Accessibility](https://www.ag-grid.com/charts/core/accessibility/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github), [Tooltips](https://www.ag-grid.com/charts/core/tooltips/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github), [Themes](https://www.ag-grid.com/charts/core/themes/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github), [Markers](https://www.ag-grid.com/charts/core/markers/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github), [Legends](https://www.ag-grid.com/charts/core/legend/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github), [Axis Types](https://www.ag-grid.com/charts/core/axes-types/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) and [Secondary Axes](https://www.ag-grid.com/charts/core/axes-secondary/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github).
|
||||
- `ag-charts-enterprise` is available under a commercial license and comes with additional series types, such as [Maps](https://www.ag-grid.com/charts/core/maps/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github), [Sankey](https://www.ag-grid.com/charts/core/sankey-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github), [Radar](https://www.ag-grid.com/charts/core/radar-area-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github), and [Waterfall](https://www.ag-grid.com/charts/core/waterfall-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) Charts as well as advanced interactivity features, like [Animations](https://www.ag-grid.com/charts/core/animation/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github), [Context Menus](https://www.ag-grid.com/charts/core/context-menu/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github), [Zooming](https://www.ag-grid.com/charts/core/zoom/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github), [Navigators](https://www.ag-grid.com/charts/core/navigator/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github), [Synchronization](https://www.ag-grid.com/charts/core/sync/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) and much more, including [Financial Charts](https://www.ag-grid.com/charts/core/financial-charts/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github).
|
||||
|
||||
### Features & Chart Types
|
||||
|
||||
#### Chart Types
|
||||
|
||||
AG Charts offers 20+ Core Chart types, each of which are fully customisable:
|
||||
|
||||
| Chart Type | AG Charts Community | AG Charts Enterprise |
|
||||
| ------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------- | -------------------- |
|
||||
| [Bar](https://www.ag-grid.com/charts/core/bar-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ✅ | ✅ |
|
||||
| [Line](https://www.ag-grid.com/charts/core/line-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ✅ | ✅ |
|
||||
| [Area](https://www.ag-grid.com/charts/core/area-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ✅ | ✅ |
|
||||
| [Scatter](https://www.ag-grid.com/charts/core/scatter-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ✅ | ✅ |
|
||||
| [Bubble](https://www.ag-grid.com/charts/core/bubble-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ✅ | ✅ |
|
||||
| [Pie](https://www.ag-grid.com/charts/core/pie-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ✅ | ✅ |
|
||||
| [Donut](https://www.ag-grid.com/charts/core/donut-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ✅ | ✅ |
|
||||
| [Combination](https://www.ag-grid.com/charts/core/combination-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ✅ | ✅ |
|
||||
| [Box Plot](https://www.ag-grid.com/charts/core/box-plot-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Candlestick](https://www.ag-grid.com/charts/core/candlestick-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [OHLC](https://www.ag-grid.com/charts/core/ohlc-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Heatmap](https://www.ag-grid.com/charts/core/heatmap-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Histogram](https://www.ag-grid.com/charts/core/histogram-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Nightingale](https://www.ag-grid.com/charts/core/nightingale-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Radar Line](https://www.ag-grid.com/charts/core/radar-line-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Radar Area](https://www.ag-grid.com/charts/core/radar-area-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Radial Column](https://www.ag-grid.com/charts/core/radial-column-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Radial Bar](https://www.ag-grid.com/charts/core/radial-bar-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Range Area](https://www.ag-grid.com/charts/core/range-area-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Range Bar](https://www.ag-grid.com/charts/core/range-bar-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Sunburst](https://www.ag-grid.com/charts/core/sunburst-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Treemap](https://www.ag-grid.com/charts/core/treemap-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Waterfall](https://www.ag-grid.com/charts/core/waterfall-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Sankey](https://www.ag-grid.com/charts/core/sankey-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Chord](https://www.ag-grid.com/charts/core/chord-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
|
||||
#### Features
|
||||
|
||||
AG Charts Core Charting Library comes with every feature you'd expect:
|
||||
|
||||
| Feature | AG Charts Community | AG Charts Enterprise |
|
||||
| --------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------- | -------------------- |
|
||||
| [Accessibility](https://www.ag-grid.com/charts/core/accessibility/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ✅ | ✅ |
|
||||
| [Localisation](https://www.ag-grid.com/charts/core/localisation/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ✅ | ✅ |
|
||||
| [Series Highlighting](https://www.ag-grid.com/charts/core/series-highlighting/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ✅ | ✅ |
|
||||
| [Tooltips](https://www.ag-grid.com/charts/core/tooltips/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ✅ | ✅ |
|
||||
| [Touch](https://www.ag-grid.com/charts/core/touch/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ✅ | ✅ |
|
||||
| [Cross Lines](https://www.ag-grid.com/charts/core/axes-cross-lines/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ✅ | ✅ |
|
||||
| [Legend](https://www.ag-grid.com/charts/core/legend/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ✅ | ✅ |
|
||||
| [Stylers](https://www.ag-grid.com/charts/core/stylers/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ✅ | ✅ |
|
||||
| [Series Markers](https://www.ag-grid.com/charts/core/markers/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ✅ | ✅ |
|
||||
| [Animations](https://www.ag-grid.com/charts/core/animation/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Context Menu](https://www.ag-grid.com/charts/core/context-menu/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Crosshairs & Band Highlight](https://www.ag-grid.com/charts/core/axes-crosshairs/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Navigator](https://www.ag-grid.com/charts/core/navigator/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Synchronization](https://www.ag-grid.com/charts/core/sync/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Zoom](https://www.ag-grid.com/charts/core/zoom/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Annotations](https://www.ag-grid.com/charts/core/annotations/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
| [Error Bars](https://www.ag-grid.com/charts/core/error-bars/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) | ❌ | ✅ |
|
||||
|
||||
<blockquote>
|
||||
<p>ℹ️ <b>Note:</b></p>
|
||||
<span>Visit the <a href="https://www.ag-grid.com/charts/license-pricing/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github">Pricing</a> page for a full comparison.</span>
|
||||
</blockquote>
|
||||
|
||||
### Financial Charts
|
||||
|
||||
Build interactive financial charts featuring advanced annotations with minimal configuration, all you need to do is provide your data:
|
||||
|
||||
<!-- START FINANCIAL CHARTS CODE SNIPPET -->
|
||||
|
||||
```js
|
||||
const options = {
|
||||
data: getData(),
|
||||
};
|
||||
|
||||
AgCharts.createFinancialChart(options);
|
||||
```
|
||||
|
||||
<!-- END FINANCIAL CHARTS CODE SNIPPET -->
|
||||
|
||||
Once created, users will have a Financial Chart that they can interact with and add annotations to.
|
||||
|
||||
<picture>
|
||||
<source media="(prefers-color-scheme: light)" srcset="https://github.com/ag-grid/ag-charts/blob/latest/packages/ag-charts-website/public/images/readme-assets/financial-charts-annotations-light.gif?raw=true"/>
|
||||
<source media="(prefers-color-scheme: dark)" srcset="https://github.com/ag-grid/ag-charts/blob/latest/packages/ag-charts-website/public/images/readme-assets/financial-charts-annotations.gif?raw=true"/>
|
||||
<img width="100%" alt="Financial Charts Annotations" src="https://github.com/ag-grid/ag-charts/blob/latest/packages/ag-charts-website/public/images/readme-assets/financial-charts-annotations-light.gif?raw=true"/>
|
||||
<br>
|
||||
</picture>
|
||||
|
||||
The default chart type is [Candlestick](https://www.ag-grid.com/charts/core/candlestick-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github), with additional types like [OHLC](https://www.ag-grid.com/charts/core/ohlc-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) and [Line](https://www.ag-grid.com/charts/core/line-series/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) for versatile data visualisation.
|
||||
|
||||
<div align="right">
|
||||
<a href="https://www.ag-grid.com/charts/core/financial-charts/"><br><img alt="Static Badge" src="https://img.shields.io/badge/Learn More-blue?style=for-the-badge&logo=data%3Aimage%2Fsvg%2Bxml%3Bbase64%2CPCFET0NUWVBFIHN2ZyBQVUJMSUMgIi0vL1czQy8vRFREIFNWRyAxLjEvL0VOIiAiaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEuZHRkIj4KDTwhLS0gVXBsb2FkZWQgdG86IFNWRyBSZXBvLCB3d3cuc3ZncmVwby5jb20sIFRyYW5zZm9ybWVkIGJ5OiBTVkcgUmVwbyBNaXhlciBUb29scyAtLT4KPHN2ZyB3aWR0aD0iODAwcHgiIGhlaWdodD0iODAwcHgiIHZpZXdCb3g9IjAgMCAyNCAyNCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KDTxnIGlkPSJTVkdSZXBvX2JnQ2FycmllciIgc3Ryb2tlLXdpZHRoPSIwIi8%2BCg08ZyBpZD0iU1ZHUmVwb190cmFjZXJDYXJyaWVyIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4KDTxnIGlkPSJTVkdSZXBvX2ljb25DYXJyaWVyIj4gPHBhdGggZD0iTTE4IDIwLjc1SDZDNS4yNzA2NSAyMC43NSA0LjU3MTE4IDIwLjQ2MDMgNC4wNTU0NiAxOS45NDQ1QzMuNTM5NzMgMTkuNDI4OCAzLjI1IDE4LjcyOTMgMy4yNSAxOFY2QzMuMjUgNS4yNzA2NSAzLjUzOTczIDQuNTcxMTggNC4wNTU0NiA0LjA1NTQ2QzQuNTcxMTggMy41Mzk3MyA1LjI3MDY1IDMuMjUgNiAzLjI1SDEyQzEyLjE5ODkgMy4yNSAxMi4zODk3IDMuMzI5MDIgMTIuNTMwMyAzLjQ2OTY3QzEyLjY3MSAzLjYxMDMyIDEyLjc1IDMuODAxMDkgMTIuNzUgNEMxMi43NSA0LjE5ODkxIDEyLjY3MSA0LjM4OTY4IDEyLjUzMDMgNC41MzAzM0MxMi4zODk3IDQuNjcwOTggMTIuMTk4OSA0Ljc1IDEyIDQuNzVINkM1LjY2ODQ4IDQuNzUgNS4zNTA1NCA0Ljg4MTcgNS4xMTYxMiA1LjExNjEyQzQuODgxNyA1LjM1MDU0IDQuNzUgNS42Njg0OCA0Ljc1IDZWMThDNC43NSAxOC4zMzE1IDQuODgxNyAxOC42NDk1IDUuMTE2MTIgMTguODgzOUM1LjM1MDU0IDE5LjExODMgNS42Njg0OCAxOS4yNSA2IDE5LjI1SDE4QzE4LjMzMTUgMTkuMjUgMTguNjQ5NSAxOS4xMTgzIDE4Ljg4MzkgMTguODgzOUMxOS4xMTgzIDE4LjY0OTUgMTkuMjUgMTguMzMxNSAxOS4yNSAxOFYxMkMxOS4yNSAxMS44MDExIDE5LjMyOSAxMS42MTAzIDE5LjQ2OTcgMTEuNDY5N0MxOS42MTAzIDExLjMyOSAxOS44MDExIDExLjI1IDIwIDExLjI1QzIwLjE5ODkgMTEuMjUgMjAuMzg5NyAxMS4zMjkgMjAuNTMwMyAxMS40Njk3QzIwLjY3MSAxMS42MTAzIDIwLjc1IDExLjgwMTEgMjAuNzUgMTJWMThDMjAuNzUgMTguNzI5MyAyMC40NjAzIDE5LjQyODggMTkuOTQ0NSAxOS45NDQ1QzE5LjQyODggMjAuNDYwMyAxOC43MjkzIDIwLjc1IDE4IDIwLjc1WiIgZmlsbD0iI2ZmZmZmZiIvPiA8cGF0aCBkPSJNMjAgOC43NUMxOS44MDE5IDguNzQ3NDEgMTkuNjEyNiA4LjY2NzU2IDE5LjQ3MjUgOC41Mjc0N0MxOS4zMzI0IDguMzg3MzcgMTkuMjUyNiA4LjE5ODExIDE5LjI1IDhWNC43NUgxNkMxNS44MDExIDQuNzUgMTUuNjEwMyA0LjY3MDk4IDE1LjQ2OTcgNC41MzAzM0MxNS4zMjkgNC4zODk2OCAxNS4yNSA0LjE5ODkxIDE1LjI1IDRDMTUuMjUgMy44MDEwOSAxNS4zMjkgMy42MTAzMiAxNS40Njk3IDMuNDY5NjdDMTUuNjEwMyAzLjMyOTAyIDE1LjgwMTEgMy4yNSAxNiAzLjI1SDIwQzIwLjE5ODEgMy4yNTI1OSAyMC4zODc0IDMuMzMyNDQgMjAuNTI3NSAzLjQ3MjUzQzIwLjY2NzYgMy42MTI2MyAyMC43NDc0IDMuODAxODkgMjAuNzUgNFY4QzIwLjc0NzQgOC4xOTgxMSAyMC42Njc2IDguMzg3MzcgMjAuNTI3NSA4LjUyNzQ3QzIwLjM4NzQgOC42Njc1NiAyMC4xOTgxIDguNzQ3NDEgMjAgOC43NVoiIGZpbGw9IiNmZmZmZmYiLz4gPHBhdGggZD0iTTEzLjUgMTEuMjVDMTMuMzA3MSAxMS4yMzUyIDEzLjEyNzYgMTEuMTQ1NSAxMyAxMUMxMi44NzcgMTAuODYyNSAxMi44MDkgMTAuNjg0NSAxMi44MDkgMTAuNUMxMi44MDkgMTAuMzE1NSAxMi44NzcgMTAuMTM3NSAxMyAxMEwxOS41IDMuNUMxOS41Njg3IDMuNDI2MzEgMTkuNjUxNSAzLjM2NzIxIDE5Ljc0MzUgMy4zMjYyMkMxOS44MzU1IDMuMjg1MjMgMTkuOTM0OCAzLjI2MzE5IDIwLjAzNTUgMy4yNjE0MUMyMC4xMzYyIDMuMjU5NjMgMjAuMjM2MiAzLjI3ODE2IDIwLjMyOTYgMy4zMTU4OEMyMC40MjMgMy4zNTM2IDIwLjUwNzggMy40MDk3NCAyMC41NzkgMy40ODA5NkMyMC42NTAzIDMuNTUyMTggMjAuNzA2NCAzLjYzNzAxIDIwLjc0NDEgMy43MzA0QzIwLjc4MTggMy44MjM3OSAyMC44MDA0IDMuOTIzODIgMjAuNzk4NiA0LjAyNDUyQzIwLjc5NjggNC4xMjUyMyAyMC43NzQ4IDQuMjI0NTQgMjAuNzMzOCA0LjMxNjU0QzIwLjY5MjggNC40MDg1NCAyMC42MzM3IDQuNDkxMzQgMjAuNTYgNC41NkwxNCAxMUMxMy44NzI0IDExLjE0NTUgMTMuNjkyOSAxMS4yMzUyIDEzLjUgMTEuMjVaIiBmaWxsPSIjZmZmZmZmIi8%2BIDwvZz4KDTwvc3ZnPg%3D%3D"></a>
|
||||
</div>
|
||||
|
||||
---
|
||||
|
||||
### Maps
|
||||
|
||||
The Maps Series let you visualise geographic data in different ways.
|
||||
|
||||
<picture>
|
||||
<source media="(prefers-color-scheme: light)" srcset="https://github.com/ag-grid/ag-charts/blob/latest/packages/ag-charts-website/public/images/readme-assets/map.gif?raw=true"/>
|
||||
<source media="(prefers-color-scheme: dark)" srcset="https://github.com/ag-grid/ag-charts/blob/latest/packages/ag-charts-website/public/images/readme-assets/map-dark.gif?raw=true"/>
|
||||
<img width="100%" alt="Preview of Map Charts from AG Charts" src="https://github.com/ag-grid/ag-charts/blob/latest/packages/ag-charts-website/public/images/readme-assets/map.gif?raw=true"/>
|
||||
</picture>
|
||||
|
||||
Maps can display data using [Shapes](https://www.ag-grid.com/charts/core/map-shapes/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github), [Lines](https://www.ag-grid.com/charts/core/map-lines/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) and [Marker](https://www.ag-grid.com/charts/core/map-markers/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) series:
|
||||
|
||||
```js
|
||||
const options = {
|
||||
topology: topology,
|
||||
series: [
|
||||
{
|
||||
type: 'map-shape',
|
||||
data: pacific,
|
||||
idKey: 'name',
|
||||
title: 'Pacific',
|
||||
},
|
||||
// ...
|
||||
],
|
||||
legend: {
|
||||
enabled: true,
|
||||
},
|
||||
// ...
|
||||
};
|
||||
```
|
||||
|
||||
<div align="right">
|
||||
<a href="https://www.ag-grid.com/charts/core/maps/"><img alt="Static Badge" src="https://img.shields.io/badge/Learn More-blue?style=for-the-badge&logo=data%3Aimage%2Fsvg%2Bxml%3Bbase64%2CPCFET0NUWVBFIHN2ZyBQVUJMSUMgIi0vL1czQy8vRFREIFNWRyAxLjEvL0VOIiAiaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEuZHRkIj4KDTwhLS0gVXBsb2FkZWQgdG86IFNWRyBSZXBvLCB3d3cuc3ZncmVwby5jb20sIFRyYW5zZm9ybWVkIGJ5OiBTVkcgUmVwbyBNaXhlciBUb29scyAtLT4KPHN2ZyB3aWR0aD0iODAwcHgiIGhlaWdodD0iODAwcHgiIHZpZXdCb3g9IjAgMCAyNCAyNCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KDTxnIGlkPSJTVkdSZXBvX2JnQ2FycmllciIgc3Ryb2tlLXdpZHRoPSIwIi8%2BCg08ZyBpZD0iU1ZHUmVwb190cmFjZXJDYXJyaWVyIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4KDTxnIGlkPSJTVkdSZXBvX2ljb25DYXJyaWVyIj4gPHBhdGggZD0iTTE4IDIwLjc1SDZDNS4yNzA2NSAyMC43NSA0LjU3MTE4IDIwLjQ2MDMgNC4wNTU0NiAxOS45NDQ1QzMuNTM5NzMgMTkuNDI4OCAzLjI1IDE4LjcyOTMgMy4yNSAxOFY2QzMuMjUgNS4yNzA2NSAzLjUzOTczIDQuNTcxMTggNC4wNTU0NiA0LjA1NTQ2QzQuNTcxMTggMy41Mzk3MyA1LjI3MDY1IDMuMjUgNiAzLjI1SDEyQzEyLjE5ODkgMy4yNSAxMi4zODk3IDMuMzI5MDIgMTIuNTMwMyAzLjQ2OTY3QzEyLjY3MSAzLjYxMDMyIDEyLjc1IDMuODAxMDkgMTIuNzUgNEMxMi43NSA0LjE5ODkxIDEyLjY3MSA0LjM4OTY4IDEyLjUzMDMgNC41MzAzM0MxMi4zODk3IDQuNjcwOTggMTIuMTk4OSA0Ljc1IDEyIDQuNzVINkM1LjY2ODQ4IDQuNzUgNS4zNTA1NCA0Ljg4MTcgNS4xMTYxMiA1LjExNjEyQzQuODgxNyA1LjM1MDU0IDQuNzUgNS42Njg0OCA0Ljc1IDZWMThDNC43NSAxOC4zMzE1IDQuODgxNyAxOC42NDk1IDUuMTE2MTIgMTguODgzOUM1LjM1MDU0IDE5LjExODMgNS42Njg0OCAxOS4yNSA2IDE5LjI1SDE4QzE4LjMzMTUgMTkuMjUgMTguNjQ5NSAxOS4xMTgzIDE4Ljg4MzkgMTguODgzOUMxOS4xMTgzIDE4LjY0OTUgMTkuMjUgMTguMzMxNSAxOS4yNSAxOFYxMkMxOS4yNSAxMS44MDExIDE5LjMyOSAxMS42MTAzIDE5LjQ2OTcgMTEuNDY5N0MxOS42MTAzIDExLjMyOSAxOS44MDExIDExLjI1IDIwIDExLjI1QzIwLjE5ODkgMTEuMjUgMjAuMzg5NyAxMS4zMjkgMjAuNTMwMyAxMS40Njk3QzIwLjY3MSAxMS42MTAzIDIwLjc1IDExLjgwMTEgMjAuNzUgMTJWMThDMjAuNzUgMTguNzI5MyAyMC40NjAzIDE5LjQyODggMTkuOTQ0NSAxOS45NDQ1QzE5LjQyODggMjAuNDYwMyAxOC43MjkzIDIwLjc1IDE4IDIwLjc1WiIgZmlsbD0iI2ZmZmZmZiIvPiA8cGF0aCBkPSJNMjAgOC43NUMxOS44MDE5IDguNzQ3NDEgMTkuNjEyNiA4LjY2NzU2IDE5LjQ3MjUgOC41Mjc0N0MxOS4zMzI0IDguMzg3MzcgMTkuMjUyNiA4LjE5ODExIDE5LjI1IDhWNC43NUgxNkMxNS44MDExIDQuNzUgMTUuNjEwMyA0LjY3MDk4IDE1LjQ2OTcgNC41MzAzM0MxNS4zMjkgNC4zODk2OCAxNS4yNSA0LjE5ODkxIDE1LjI1IDRDMTUuMjUgMy44MDEwOSAxNS4zMjkgMy42MTAzMiAxNS40Njk3IDMuNDY5NjdDMTUuNjEwMyAzLjMyOTAyIDE1LjgwMTEgMy4yNSAxNiAzLjI1SDIwQzIwLjE5ODEgMy4yNTI1OSAyMC4zODc0IDMuMzMyNDQgMjAuNTI3NSAzLjQ3MjUzQzIwLjY2NzYgMy42MTI2MyAyMC43NDc0IDMuODAxODkgMjAuNzUgNFY4QzIwLjc0NzQgOC4xOTgxMSAyMC42Njc2IDguMzg3MzcgMjAuNTI3NSA4LjUyNzQ3QzIwLjM4NzQgOC42Njc1NiAyMC4xOTgxIDguNzQ3NDEgMjAgOC43NVoiIGZpbGw9IiNmZmZmZmYiLz4gPHBhdGggZD0iTTEzLjUgMTEuMjVDMTMuMzA3MSAxMS4yMzUyIDEzLjEyNzYgMTEuMTQ1NSAxMyAxMUMxMi44NzcgMTAuODYyNSAxMi44MDkgMTAuNjg0NSAxMi44MDkgMTAuNUMxMi44MDkgMTAuMzE1NSAxMi44NzcgMTAuMTM3NSAxMyAxMEwxOS41IDMuNUMxOS41Njg3IDMuNDI2MzEgMTkuNjUxNSAzLjM2NzIxIDE5Ljc0MzUgMy4zMjYyMkMxOS44MzU1IDMuMjg1MjMgMTkuOTM0OCAzLjI2MzE5IDIwLjAzNTUgMy4yNjE0MUMyMC4xMzYyIDMuMjU5NjMgMjAuMjM2MiAzLjI3ODE2IDIwLjMyOTYgMy4zMTU4OEMyMC40MjMgMy4zNTM2IDIwLjUwNzggMy40MDk3NCAyMC41NzkgMy40ODA5NkMyMC42NTAzIDMuNTUyMTggMjAuNzA2NCAzLjYzNzAxIDIwLjc0NDEgMy43MzA0QzIwLjc4MTggMy44MjM3OSAyMC44MDA0IDMuOTIzODIgMjAuNzk4NiA0LjAyNDUyQzIwLjc5NjggNC4xMjUyMyAyMC43NzQ4IDQuMjI0NTQgMjAuNzMzOCA0LjMxNjU0QzIwLjY5MjggNC40MDg1NCAyMC42MzM3IDQuNDkxMzQgMjAuNTYgNC41NkwxNCAxMUMxMy44NzI0IDExLjE0NTUgMTMuNjkyOSAxMS4yMzUyIDEzLjUgMTEuMjVaIiBmaWxsPSIjZmZmZmZmIi8%2BIDwvZz4KDTwvc3ZnPg%3D%3D"></a>
|
||||
</div>
|
||||
|
||||
## ⚡️ Quick Start
|
||||
|
||||
<!-- START QUICK START DESCRIPTION -->
|
||||
|
||||
AG Charts are easy to set up - all you need to do is provide your data and series type along with any other chart options. Read on for vanilla Core installation instructions, or refer to our framework-specific guides for <strong><a href="https://github.com/ag-grid/ag-charts/tree/latest/packages/ag-charts-react"><img src="https://github.com/ag-grid/ag-grid/blob/latest/documentation/ag-grid-docs/public/images/fw-logos/react.svg?raw=true" height="16" width="16" alt="React Logo"> React</a></strong>, <strong><a href="https://github.com/ag-grid/ag-charts/tree/latest/packages/ag-charts-angular"><img src="https://github.com/ag-grid/ag-grid/blob/latest/documentation/ag-grid-docs/public/images/fw-logos/angular.svg?raw=true" height="16" width="16" alt="Angular Logo"> Angular</a></strong> and <strong><a href="https://github.com/ag-grid/ag-charts/tree/latest/packages/ag-charts-vue3"><img src="https://github.com/ag-grid/ag-grid/blob/latest/documentation/ag-grid-docs/public/images/fw-logos/vue.svg?raw=true" height="16" width="16" alt="Vue Logo"> Vue</a></strong>.
|
||||
|
||||
<!-- END QUICK START DESCRIPTION -->
|
||||
|
||||
### Installation
|
||||
|
||||
```sh
|
||||
$ npm install ag-charts-core
|
||||
```
|
||||
|
||||
### Setup
|
||||
|
||||
<!-- START SETUP -->
|
||||
|
||||
1. Provide a Container
|
||||
|
||||
```html
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<title>AG Charts Quick Start</title>
|
||||
<!-- Core Charts Core Library -->
|
||||
<script src="https://cdn.jsdelivr.net/npm/ag-charts-core/dist/umd/ag-charts-core.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<!-- Container for Chart -->
|
||||
<div id="myChart"></div>
|
||||
<!-- Charts configuration file -->
|
||||
<script src="index.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
```
|
||||
|
||||
2. Instantiate the Core Chart
|
||||
|
||||
```js
|
||||
// Chart Options
|
||||
const options = {};
|
||||
|
||||
// Create Chart
|
||||
const chart = agCharts.AgCharts.create(options);
|
||||
```
|
||||
|
||||
3. Define Chart Data and Series
|
||||
|
||||
```js
|
||||
// Chart Options
|
||||
const options = {
|
||||
// Container: HTML Element to hold the chart
|
||||
container: document.getElementById('myChart'),
|
||||
// Data: Data to be displayed in the chart
|
||||
data: [
|
||||
{ month: 'Jan', avgTemp: 2.3, iceCreamSales: 162000 },
|
||||
{ month: 'Mar', avgTemp: 6.3, iceCreamSales: 302000 },
|
||||
{ month: 'May', avgTemp: 16.2, iceCreamSales: 800000 },
|
||||
{ month: 'Jul', avgTemp: 22.8, iceCreamSales: 1254000 },
|
||||
{ month: 'Sep', avgTemp: 14.5, iceCreamSales: 950000 },
|
||||
{ month: 'Nov', avgTemp: 8.9, iceCreamSales: 200000 },
|
||||
],
|
||||
// Series: Defines which chart type and data to use
|
||||
series: [{ type: 'bar', xKey: 'month', yKey: 'iceCreamSales' }],
|
||||
};
|
||||
```
|
||||
|
||||
<!-- END SETUP -->
|
||||
|
||||
<blockquote>
|
||||
<p>ℹ️ <b>Note:</b></p>
|
||||
<span>For more information on building Core Charts with AG Charts, refer to our <a href="https://www.ag-grid.com/charts/core/quick-start/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github">Documentation</a>.</span>
|
||||
</blockquote>
|
||||
|
||||
## 🤝 Support
|
||||
|
||||
### Enterprise Support
|
||||
|
||||
AG Charts Enterprise customers have access to dedicated support via [ZenDesk](https://ag-grid.zendesk.com/hc/en-us), which is monitored by our support & engineering teams.
|
||||
|
||||
### Bug Reports
|
||||
|
||||
If you have found a bug, please report it in this repository's [issues](https://github.com/ag-grid/ag-charts/issues) section.
|
||||
|
||||
<img src="https://img.shields.io/github/issues-closed/ag-grid/ag-charts?style=for-the-badge&color=%233d8c40" alt="GitHub Issues" height="26">
|
||||
|
||||
### Questions
|
||||
|
||||
Look for similar problems on [StackOverflow](https://stackoverflow.com/questions/tagged/ag-charts) using the `ag-charts` tag. If nothing seems related, post a new message there. Please do not use GitHub issues to ask questions.
|
||||
|
||||
<img src="https://img.shields.io/stackexchange/stackoverflow.com/t/ag-charts?style=for-the-badge&color=%233d8c40" alt="Stack Exchange questions" height="26">
|
||||
|
||||
### Contributing
|
||||
|
||||
AG Charts is developed by a team of co-located developers in London. If you want to join the team send your application to info@ag-grid.com.
|
||||
|
||||
## ⚠️ License
|
||||
|
||||
`ag-charts-community` is licensed under the **MIT** license.
|
||||
|
||||
`ag-charts-enterprise` has a **Commercial** license.
|
||||
|
||||
See the [LICENSE file](./LICENSE.txt) for more info.
|
||||
|
||||
<div><h2><img vertical-align="middle" width="32" height="32" src="https://github.com/ag-grid/ag-grid/blob/latest/documentation/ag-grid-docs/public/images/ag-logos/svg-logos/AG-BrandMark_Light-Theme.svg?raw=true" alt="AG ChartsLogo">AG Grid</h2></div>
|
||||
|
||||
<p>AG Grid is our flagship product, a <strong>fully-featured</strong> and <strong>highly customizable</strong> Core Data Grid. It delivers <strong>outstanding performance</strong>, has <strong>no third-party dependencies</strong> and comes with support for <strong><a href="https://github.com/ag-grid/ag-grid/tree/latest/packages/ag-grid-react"><img src="https://github.com/ag-grid/ag-grid/blob/latest/documentation/ag-grid-docs/public/images/fw-logos/react.svg?raw=true" height="16" width="16" alt="React Logo"> React</a></strong>, <strong><a href="https://github.com/ag-grid/ag-grid/tree/latest/packages/ag-grid-angular"><img src="https://github.com/ag-grid/ag-grid/blob/latest/documentation/ag-grid-docs/public/images/fw-logos/angular.svg?raw=true" height="16" width="16" alt="Angular Logo"> Angular</a></strong> and <strong><a href="https://github.com/ag-grid/ag-grid/tree/latest/packages/ag-grid-vue3"><img src="https://github.com/ag-grid/ag-grid/blob/latest/documentation/ag-grid-docs/public/images/fw-logos/vue.svg?raw=true" height="16" width="16" alt="Vue Logo"> Vue</a></strong>.</p>
|
||||
|
||||
AG Charts is used within AG Grid to power the [Integrated Charting](https://www.ag-grid.com/core-data-grid/integrated-charts/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github) feature.
|
||||
|
||||
Learn more at [ag-grid.com](https://www.ag-grid.com/?utm_source=ag-charts-readme&utm_medium=repository&utm_campaign=github)
|
||||
|
||||
<div align="center">
|
||||
|
||||
<hr/>
|
||||
|
||||
<strong>Follow us to keep up to date with all the latest news from AG Grid:</strong>
|
||||
|
||||
<a href="https://x.com/ag_grid"><img src="https://img.shields.io/badge/-X%20(Twitter)-black?style=for-the-badge&logo=x" alt="Twitter Badge" height="36"></a>
|
||||
<a href="https://www.linkedin.com/company/ag-grid/"><img src="https://img.shields.io/badge/-LinkedIn-blue?style=for-the-badge&logo=linkedin" alt="LinkedIn Badge" height="36"></a>
|
||||
<a href="https://www.youtube.com/c/ag-grid"><img src="https://img.shields.io/badge/-YouTube-red?style=for-the-badge&logo=youtube" alt="YouTube Badge" height="36"></a>
|
||||
<a href="https://blog.ag-grid.com"><img src="https://img.shields.io/badge/-Blog-grey?style=for-the-badge&logo=rss" alt="Blog Badge" height="36"></a>
|
||||
|
||||
</div>
|
||||
9582
node_modules/ag-charts-core/dist/package/main.cjs.js
generated
vendored
Executable file
9582
node_modules/ag-charts-core/dist/package/main.cjs.js
generated
vendored
Executable file
File diff suppressed because it is too large
Load Diff
12
node_modules/ag-charts-core/dist/package/main.cjs.min.js
generated
vendored
Executable file
12
node_modules/ag-charts-core/dist/package/main.cjs.min.js
generated
vendored
Executable file
File diff suppressed because one or more lines are too long
12
node_modules/ag-charts-core/dist/package/main.esm.min.mjs
generated
vendored
Executable file
12
node_modules/ag-charts-core/dist/package/main.esm.min.mjs
generated
vendored
Executable file
File diff suppressed because one or more lines are too long
9566
node_modules/ag-charts-core/dist/package/main.esm.mjs
generated
vendored
Executable file
9566
node_modules/ag-charts-core/dist/package/main.esm.mjs
generated
vendored
Executable file
File diff suppressed because it is too large
Load Diff
6
node_modules/ag-charts-core/dist/types/src/chart/interpolationProperties.d.ts
generated
vendored
Executable file
6
node_modules/ag-charts-core/dist/types/src/chart/interpolationProperties.d.ts
generated
vendored
Executable file
@@ -0,0 +1,6 @@
|
||||
import { BaseProperties } from '../state/properties';
|
||||
export declare class InterpolationProperties extends BaseProperties {
|
||||
type: 'linear' | 'smooth' | 'step';
|
||||
tension: number;
|
||||
position: 'start' | 'middle' | 'end';
|
||||
}
|
||||
2
node_modules/ag-charts-core/dist/types/src/chart/legendUtil.d.ts
generated
vendored
Executable file
2
node_modules/ag-charts-core/dist/types/src/chart/legendUtil.d.ts
generated
vendored
Executable file
@@ -0,0 +1,2 @@
|
||||
import type { AgChartLegendPosition, AgChartLegendPositionOptions } from 'ag-charts-types';
|
||||
export declare function expandLegendPosition(position: AgChartLegendPosition): Required<AgChartLegendPositionOptions>;
|
||||
24
node_modules/ag-charts-core/dist/types/src/config/chartDefaults.d.ts
generated
vendored
Executable file
24
node_modules/ag-charts-core/dist/types/src/config/chartDefaults.d.ts
generated
vendored
Executable file
@@ -0,0 +1,24 @@
|
||||
import { type AgBaseSeriesOptions, type AgBaseSeriesThemeableOptions, type AgBaseThemeableChartOptions, type AgChartAutoSizedBaseLabelOptions, type AgChartLabelOptions, type AgDropShadowOptions, type AgErrorBarOptions, type AgErrorBarThemeableOptions, type AgInterpolationType, type AgSeriesMarkerOptions, type AgSeriesMarkerStyle, type AgSeriesTooltip, type ToolbarButton } from 'ag-charts-types';
|
||||
import { type OptionsDefs, type Validator } from '../state/validation';
|
||||
export declare const legendPositionValidator: Validator;
|
||||
export declare const shapeValidator: Validator;
|
||||
export declare const rangeValidator: Validator;
|
||||
export declare const seriesTooltipRangeValidator: Validator;
|
||||
export declare const textOrSegments: Validator;
|
||||
export declare const contextMenuItemsArray: Validator;
|
||||
export declare const toolbarButtonOptionsDefs: OptionsDefs<ToolbarButton>;
|
||||
export declare const formatObjectValidator: Validator;
|
||||
export declare const numberFormatValidator: Validator;
|
||||
export declare const commonChartOptionsDefs: OptionsDefs<Omit<AgBaseThemeableChartOptions, 'navigator'>>;
|
||||
export declare const commonSeriesThemeableOptionsDefs: OptionsDefs<AgBaseSeriesThemeableOptions<any>>;
|
||||
export declare const commonSeriesOptionsDefs: OptionsDefs<AgBaseSeriesOptions<any>>;
|
||||
export declare const markerStyleOptionsDefs: OptionsDefs<AgSeriesMarkerStyle>;
|
||||
export declare const markerOptionsDefs: OptionsDefs<AgSeriesMarkerOptions<any, any>>;
|
||||
export declare const seriesLabelOptionsDefs: OptionsDefs<AgChartLabelOptions<any, any>>;
|
||||
export declare const autoSizedLabelOptionsDefs: OptionsDefs<AgChartAutoSizedBaseLabelOptions<any, any>>;
|
||||
export declare const errorBarThemeableOptionsDefs: OptionsDefs<AgErrorBarThemeableOptions>;
|
||||
export declare const errorBarOptionsDefs: OptionsDefs<AgErrorBarOptions<any>>;
|
||||
export declare const tooltipOptionsDefs: OptionsDefs<AgSeriesTooltip<any>>;
|
||||
export declare const tooltipOptionsDefsWithArea: OptionsDefs<AgSeriesTooltip<any>>;
|
||||
export declare const shadowOptionsDefs: OptionsDefs<AgDropShadowOptions>;
|
||||
export declare const interpolationOptionsDefs: OptionsDefs<AgInterpolationType>;
|
||||
8
node_modules/ag-charts-core/dist/types/src/config/gaugePreset.d.ts
generated
vendored
Executable file
8
node_modules/ag-charts-core/dist/types/src/config/gaugePreset.d.ts
generated
vendored
Executable file
@@ -0,0 +1,8 @@
|
||||
import type { AgLinearGaugePreset, AgLinearGaugeTarget, AgLinearGaugeThemeableOptions, AgRadialGaugePreset, AgRadialGaugeTarget, AgRadialGaugeThemeableOptions } from 'ag-charts-types';
|
||||
import { type OptionsDefs } from '../state/validation';
|
||||
export declare const linearGaugeTargetOptionsDef: OptionsDefs<AgLinearGaugeTarget>;
|
||||
export declare const radialGaugeTargetOptionsDef: OptionsDefs<AgRadialGaugeTarget>;
|
||||
export declare const linearGaugeSeriesThemeableOptionsDef: OptionsDefs<AgLinearGaugeThemeableOptions>;
|
||||
export declare const linearGaugeSeriesOptionsDef: OptionsDefs<AgLinearGaugePreset>;
|
||||
export declare const radialGaugeSeriesThemeableOptionsDef: OptionsDefs<AgRadialGaugeThemeableOptions>;
|
||||
export declare const radialGaugeSeriesOptionsDef: OptionsDefs<AgRadialGaugePreset>;
|
||||
65
node_modules/ag-charts-core/dist/types/src/config/optionsDefaults.d.ts
generated
vendored
Executable file
65
node_modules/ag-charts-core/dist/types/src/config/optionsDefaults.d.ts
generated
vendored
Executable file
@@ -0,0 +1,65 @@
|
||||
import type { AgBarHighlightStyleOptions, AgGradientColor, AgGradientColorBounds, AgGradientType, AgHighlightStyleOptions, AgImageFill, AgLineHighlightStyleOptions, AgPatternColor, AgSeriesLineSegmentOptions, AgSeriesShapeSegmentOptions, BorderOptions, CssColor, FillOptions, LabelBoxOptions, LineDashOptions, StrokeOptions, TextOptions } from 'ag-charts-types';
|
||||
import { type OptionsDefs } from '../state/validation';
|
||||
export declare const themeOperator: (value: unknown) => boolean;
|
||||
export declare const colorStopsOrderValidator: import("../state/validation").Validator;
|
||||
export declare const gradientColorStops: import("../state/validation").Validator;
|
||||
export declare const gradientStrict: import("../state/validation").Validator;
|
||||
export interface InternalAgGradientColor extends AgGradientColor {
|
||||
/** Format of the gradient */
|
||||
gradient?: AgGradientType;
|
||||
/** The domain of the colour gradient, defaults to item. */
|
||||
bounds?: AgGradientColorBounds;
|
||||
/** Reverse the order of colour stops. */
|
||||
reverse?: boolean;
|
||||
/** Colour space to use when interpolating colours in the gradient. */
|
||||
colorSpace?: ColorSpace;
|
||||
}
|
||||
export type ColorSpace = 'rgb' | 'oklch';
|
||||
export interface InternalAgPatternColor extends AgPatternColor {
|
||||
/** Padding for the shape in the pattern unit. */
|
||||
padding?: number;
|
||||
}
|
||||
export interface InternalAgImageFill extends AgImageFill {
|
||||
}
|
||||
export type RequiredInternalAgImageFill = Required<Omit<InternalAgImageFill, 'url' | 'width' | 'height'>> & Pick<Partial<InternalAgImageFill>, 'url'> & Pick<InternalAgImageFill, 'width' | 'height'>;
|
||||
export type RequiredInternalAgPatternColor = Required<Omit<InternalAgPatternColor, 'path'>> & Pick<InternalAgPatternColor, 'path'>;
|
||||
export type RequiredInternalAgGradientColor = Required<InternalAgGradientColor>;
|
||||
export type InternalAgColorType = CssColor | InternalAgGradientColor | InternalAgPatternColor | InternalAgImageFill;
|
||||
export type RequiredInternalAgColorType = CssColor | RequiredInternalAgGradientColor | RequiredInternalAgPatternColor | (RequiredInternalAgImageFill & Pick<InternalAgImageFill, 'url'>);
|
||||
export declare const strokeOptionsDef: OptionsDefs<StrokeOptions>;
|
||||
export declare const fillGradientDefaults: import("../state/validation").Validator;
|
||||
export declare const fillPatternDefaults: import("../state/validation").Validator;
|
||||
export declare const fillImageDefaults: import("../state/validation").Validator;
|
||||
export declare const colorUnion: import("../state/validation").Validator;
|
||||
export declare const fillOptionsDef: OptionsDefs<FillOptions>;
|
||||
export declare const lineDashOptionsDef: OptionsDefs<LineDashOptions>;
|
||||
export declare const barHighlightOptionsDef: OptionsDefs<AgBarHighlightStyleOptions>;
|
||||
export declare const lineHighlightOptionsDef: OptionsDefs<AgLineHighlightStyleOptions>;
|
||||
export declare const shapeHighlightOptionsDef: OptionsDefs<AgHighlightStyleOptions>;
|
||||
export declare function highlightOptionsDef<T>(itemHighlightOptionsDef: T): {
|
||||
enabled: import("../state/validation").Validator;
|
||||
range: import("../state/validation").Validator;
|
||||
highlightedItem: T;
|
||||
unhighlightedItem: T;
|
||||
};
|
||||
export declare function multiSeriesHighlightOptionsDef<I, S>(itemHighlightOptionsDef: I, seriesHighlightOptionsDef: S): {
|
||||
enabled: import("../state/validation").Validator;
|
||||
range: import("../state/validation").Validator;
|
||||
highlightedItem: I;
|
||||
unhighlightedItem: I;
|
||||
highlightedSeries: S;
|
||||
unhighlightedSeries: S;
|
||||
bringToFront: import("../state/validation").Validator;
|
||||
};
|
||||
export declare const shapeSegmentOptions: OptionsDefs<AgSeriesShapeSegmentOptions>;
|
||||
export declare const lineSegmentOptions: OptionsDefs<AgSeriesLineSegmentOptions>;
|
||||
export declare const shapeSegmentation: import("../state/validation").Validator;
|
||||
export declare const lineSegmentation: import("../state/validation").Validator;
|
||||
export declare const googleFont: import("../state/validation").Validator;
|
||||
export declare const fontFamilyFull: import("../state/validation").Validator;
|
||||
export declare const fontWeight: import("../state/validation").Validator;
|
||||
export declare const fontOptionsDef: OptionsDefs<TextOptions>;
|
||||
export declare const paddingOptions: import("../state/validation").Validator;
|
||||
export declare const padding: import("../state/validation").Validator;
|
||||
export declare const borderOptionsDef: OptionsDefs<BorderOptions>;
|
||||
export declare const labelBoxOptionsDef: OptionsDefs<LabelBoxOptions>;
|
||||
36
node_modules/ag-charts-core/dist/types/src/config/themeUtil.d.ts
generated
vendored
Executable file
36
node_modules/ag-charts-core/dist/types/src/config/themeUtil.d.ts
generated
vendored
Executable file
@@ -0,0 +1,36 @@
|
||||
import type { AgCartesianChartOptions, AgHighlightOptions, AgHighlightStyleOptions, AgMultiSeriesHighlightOptions, AgSeriesSegmentation, LabelBoxOptions, WithThemeParams } from 'ag-charts-types';
|
||||
import { type RequiredInternalAgGradientColor, type RequiredInternalAgImageFill, type RequiredInternalAgPatternColor } from './optionsDefaults';
|
||||
type CartesianAxis = Exclude<AgCartesianChartOptions['axes'], undefined>[0];
|
||||
export declare const DIRECTION_SWAP_AXES: WithThemeParams<Record<string, CartesianAxis>>;
|
||||
export declare const SAFE_FILL_OPERATION: any;
|
||||
export declare const SAFE_FILLS_OPERATION: any;
|
||||
export declare const SAFE_STROKE_FILL_OPERATION: any;
|
||||
export declare const SAFE_RANGE2_OPERATION: any;
|
||||
export declare const FILL_GRADIENT_BLANK_DEFAULTS: RequiredInternalAgGradientColor;
|
||||
export declare const FILL_GRADIENT_LINEAR_DEFAULTS: WithThemeParams<RequiredInternalAgGradientColor>;
|
||||
export declare const FILL_GRADIENT_LINEAR_HIERARCHY_DEFAULTS: WithThemeParams<RequiredInternalAgGradientColor>;
|
||||
export declare const FILL_GRADIENT_LINEAR_SINGLE_DEFAULTS: WithThemeParams<RequiredInternalAgGradientColor>;
|
||||
export declare const FILL_GRADIENT_LINEAR_KEYED_DEFAULTS: (key: 'up' | 'down' | 'altUp' | 'altDown' | 'neutral') => WithThemeParams<RequiredInternalAgGradientColor>;
|
||||
export declare const FILL_GRADIENT_RADIAL_DEFAULTS: WithThemeParams<RequiredInternalAgGradientColor>;
|
||||
export declare const FILL_GRADIENT_RADIAL_REVERSED_DEFAULTS: WithThemeParams<RequiredInternalAgGradientColor>;
|
||||
export declare const FILL_GRADIENT_RADIAL_SERIES_DEFAULTS: WithThemeParams<RequiredInternalAgGradientColor>;
|
||||
export declare const FILL_GRADIENT_RADIAL_REVERSED_SERIES_DEFAULTS: WithThemeParams<RequiredInternalAgGradientColor>;
|
||||
export declare const FILL_GRADIENT_CONIC_SERIES_DEFAULTS: WithThemeParams<RequiredInternalAgGradientColor>;
|
||||
export declare const FILL_PATTERN_DEFAULTS: WithThemeParams<RequiredInternalAgPatternColor>;
|
||||
export declare const FILL_PATTERN_SINGLE_DEFAULTS: WithThemeParams<RequiredInternalAgPatternColor>;
|
||||
export declare const FILL_PATTERN_BLANK_DEFAULTS: RequiredInternalAgPatternColor;
|
||||
export declare const FILL_PATTERN_HIERARCHY_DEFAULTS: WithThemeParams<RequiredInternalAgPatternColor>;
|
||||
export declare const FILL_PATTERN_KEYED_DEFAULTS: (key: 'up' | 'down' | 'altUp' | 'altDown' | 'neutral') => WithThemeParams<RequiredInternalAgPatternColor>;
|
||||
export declare const FILL_IMAGE_DEFAULTS: WithThemeParams<RequiredInternalAgImageFill>;
|
||||
export declare const FILL_IMAGE_BLANK_DEFAULTS: RequiredInternalAgImageFill;
|
||||
export declare function getSequentialColors(colors: {
|
||||
[key: string]: string;
|
||||
}): Record<string | number, string[]>;
|
||||
export declare const LABEL_BOXING_DEFAULTS: WithThemeParams<LabelBoxOptions>;
|
||||
export declare const MULTI_SERIES_HIGHLIGHT_STYLE: WithThemeParams<AgMultiSeriesHighlightOptions<AgHighlightStyleOptions>>;
|
||||
export declare const MARKER_SERIES_HIGHLIGHT_STYLE: WithThemeParams<AgMultiSeriesHighlightOptions<AgHighlightStyleOptions>>;
|
||||
export declare const PART_WHOLE_HIGHLIGHT_STYLE: WithThemeParams<AgMultiSeriesHighlightOptions<AgHighlightStyleOptions>>;
|
||||
export declare const SINGLE_SERIES_HIGHLIGHT_STYLE: WithThemeParams<AgHighlightOptions<AgHighlightStyleOptions>>;
|
||||
export declare const LEGEND_CONTAINER_THEME: any;
|
||||
export declare const SEGMENTATION_DEFAULTS: WithThemeParams<AgSeriesSegmentation>;
|
||||
export {};
|
||||
17
node_modules/ag-charts-core/dist/types/src/identity/id.d.ts
generated
vendored
Executable file
17
node_modules/ag-charts-core/dist/types/src/identity/id.d.ts
generated
vendored
Executable file
@@ -0,0 +1,17 @@
|
||||
import type { AxisID, ElementID } from '../types/idBranding';
|
||||
type IDTypes = ElementID | AxisID;
|
||||
/**
|
||||
* Interface for classes that can have IDs generated via createId().
|
||||
* Implementing classes MUST define: static readonly className: string
|
||||
*/
|
||||
export interface Identifiable {
|
||||
constructor: {
|
||||
readonly className?: string;
|
||||
readonly name?: string;
|
||||
};
|
||||
}
|
||||
export declare function resetIds(): void;
|
||||
export declare function createId<T extends IDTypes | string = string>(instance: Identifiable): T;
|
||||
export declare function createElementId(): ElementID;
|
||||
export declare function generateUUID(): string;
|
||||
export {};
|
||||
1
node_modules/ag-charts-core/dist/types/src/identity/idGenerator.d.ts
generated
vendored
Executable file
1
node_modules/ag-charts-core/dist/types/src/identity/idGenerator.d.ts
generated
vendored
Executable file
@@ -0,0 +1 @@
|
||||
export declare function createIdsGenerator(): (name: string) => string;
|
||||
16
node_modules/ag-charts-core/dist/types/src/logging/debugLogger.d.ts
generated
vendored
Executable file
16
node_modules/ag-charts-core/dist/types/src/logging/debugLogger.d.ts
generated
vendored
Executable file
@@ -0,0 +1,16 @@
|
||||
export interface DebugLogger {
|
||||
(...logContent: any[]): void;
|
||||
check(): boolean;
|
||||
group<T>(name: string, cb: () => T): T;
|
||||
}
|
||||
export declare function create(...debugSelectors: Array<boolean | string>): DebugLogger;
|
||||
export declare function check(...debugSelectors: Array<boolean | string>): boolean;
|
||||
export declare function inDevelopmentMode<R>(fn: () => R): R | undefined;
|
||||
interface DebugTimingOptions {
|
||||
logResult?: boolean;
|
||||
logStack?: boolean;
|
||||
logArgs?: boolean;
|
||||
logData?: (target: any) => any;
|
||||
}
|
||||
export declare function Time(name: string, opts?: DebugTimingOptions): (_target: any, _propertyKey: string, descriptor: PropertyDescriptor) => void;
|
||||
export {};
|
||||
2
node_modules/ag-charts-core/dist/types/src/logging/debugMetrics.d.ts
generated
vendored
Executable file
2
node_modules/ag-charts-core/dist/types/src/logging/debugMetrics.d.ts
generated
vendored
Executable file
@@ -0,0 +1,2 @@
|
||||
export declare function record(key: string, value: any): void;
|
||||
export declare function flush(): Record<string, any>;
|
||||
8
node_modules/ag-charts-core/dist/types/src/logging/logger.d.ts
generated
vendored
Executable file
8
node_modules/ag-charts-core/dist/types/src/logging/logger.d.ts
generated
vendored
Executable file
@@ -0,0 +1,8 @@
|
||||
export declare function log(...logContent: any[]): void;
|
||||
export declare function warn(message: any, ...logContent: any[]): void;
|
||||
export declare function error(message: any, ...logContent: any[]): void;
|
||||
export declare function table(...logContent: any[]): void;
|
||||
export declare function warnOnce(messageOrError: unknown, ...logContent: any[]): void;
|
||||
export declare function errorOnce(messageOrError: unknown, ...logContent: any[]): void;
|
||||
export declare function reset(): void;
|
||||
export declare function logGroup<T>(name: string, cb: () => T): T;
|
||||
100
node_modules/ag-charts-core/dist/types/src/main.d.ts
generated
vendored
Executable file
100
node_modules/ag-charts-core/dist/types/src/main.d.ts
generated
vendored
Executable file
@@ -0,0 +1,100 @@
|
||||
export * from './types/global';
|
||||
export * from './modules/moduleDefinition';
|
||||
export * from './types/scene';
|
||||
export * from './types/scales';
|
||||
export * from './structures/eventEmitter';
|
||||
export * from './structures/lruCache';
|
||||
export * as Debug from './logging/debugLogger';
|
||||
export * as Logger from './logging/logger';
|
||||
export * as DebugMetrics from './logging/debugMetrics';
|
||||
export * from './modules/enterpriseRegistry';
|
||||
export * as ModuleRegistry from './modules/moduleRegistry';
|
||||
export { AbstractModuleInstance } from './modules/moduleInstance';
|
||||
export * from './config/chartDefaults';
|
||||
export * from './config/optionsDefaults';
|
||||
export * from './config/gaugePreset';
|
||||
export * from './config/themeUtil';
|
||||
export * from './state/memento';
|
||||
export * from './types/animationPhase';
|
||||
export * from './types/axisDirection';
|
||||
export * from './types/updateType';
|
||||
export * from './types/zIndexMap';
|
||||
export * from './chart/legendUtil';
|
||||
export * from './chart/interpolationProperties';
|
||||
export * from './utils/aggregation';
|
||||
export * from './types/geojson';
|
||||
export * from './types/themeConstants';
|
||||
export * from './types/themeSymbols';
|
||||
export * from './types/text';
|
||||
export * from './state/callbackCache';
|
||||
export * from './utils/types/decorator';
|
||||
export * from './utils/dom/domUtil';
|
||||
export * from './utils/geometry/math';
|
||||
export * from './utils/data/arrays';
|
||||
export * from './utils/geometry/angle';
|
||||
export * from './utils/async';
|
||||
export * from './utils/dom/attributeUtil';
|
||||
export * from './utils/geometry/border';
|
||||
export * from './utils/geometry/boxBounds';
|
||||
export * from './utils/data/binarySearch';
|
||||
export * from './utils/format/color';
|
||||
export * from './utils/canvas';
|
||||
export * from './utils/configuredCanvasMixin';
|
||||
export * from './state/caching';
|
||||
export * from './utils/time/date';
|
||||
export * from './state/cleanupRegistry';
|
||||
export * from './utils/deprecation';
|
||||
export * from './utils/data/diff';
|
||||
export * from './utils/geometry/distance';
|
||||
export * from './utils/data/extent';
|
||||
export * from './utils/format/format.util';
|
||||
export * from './utils/functions';
|
||||
export * from './utils/geojson';
|
||||
export * from './structures/graph';
|
||||
export * from './utils/data/json';
|
||||
export * from './utils/dom/keynavUtil';
|
||||
export * from './identity/id';
|
||||
export * from './types/idBranding';
|
||||
export * from './utils/data/iterators';
|
||||
export * from './utils/data/linkedList';
|
||||
export * from './state/memo';
|
||||
export * from './utils/data/nearest';
|
||||
export * from './utils/data/numberArray';
|
||||
export * from './utils/data/numbers';
|
||||
export * from './utils/data/object';
|
||||
export * from './utils/geometry/padding';
|
||||
export * from './utils/geometry/placement';
|
||||
export * from './state/properties';
|
||||
export * from './state/proxy';
|
||||
export * from './utils/data/strings';
|
||||
export * from './state/stateMachine';
|
||||
export * from './rendering/textMeasurer';
|
||||
export * from './utils/dom/domElements';
|
||||
export * from './utils/dom/domEvents';
|
||||
export * from './utils/dom/globalsProxy';
|
||||
export * from './utils/dom/domDownload';
|
||||
export * from './utils/text/textUtils';
|
||||
export * from './utils/text/textWrapper';
|
||||
export * from './utils/time/ticks';
|
||||
export * from './utils/time/time';
|
||||
export * from './utils/time/timeFormatDefaults';
|
||||
export * from './utils/data/visibleRange';
|
||||
export * from './identity/idGenerator';
|
||||
export * from './utils/types/typeGuards';
|
||||
export * from './utils/data/value';
|
||||
export * from './state/validation';
|
||||
export * as Vec2 from './utils/geometry/vector';
|
||||
export * as Vec4 from './utils/geometry/vector4';
|
||||
export * from './utils/geometry/fill';
|
||||
export * from './utils/geometry/bezier';
|
||||
export * from './utils/geometry/labelPlacement';
|
||||
export * from './utils/geometry/scaling';
|
||||
export * from './utils/geometry/lineInterpolation';
|
||||
export * from './utils/zoomUtils';
|
||||
export * from './logging/debugMetrics';
|
||||
export { ChangeDetectableProperties } from './rendering/changeDetectableProperties';
|
||||
export * from './utils/format/numberFormat';
|
||||
export * from './utils/format/timeFormat';
|
||||
export * from './rendering/domElements';
|
||||
export * from './rendering/easing';
|
||||
export * from './rendering/changeDetectable';
|
||||
18
node_modules/ag-charts-core/dist/types/src/modules/enterpriseRegistry.d.ts
generated
vendored
Executable file
18
node_modules/ag-charts-core/dist/types/src/modules/enterpriseRegistry.d.ts
generated
vendored
Executable file
@@ -0,0 +1,18 @@
|
||||
import type { AgChartOptions } from 'ag-charts-types';
|
||||
export interface LicenseManager {
|
||||
validateLicense: () => void;
|
||||
isDisplayWatermark: () => boolean;
|
||||
getWatermarkMessage: () => string;
|
||||
getWatermarkForegroundConfig: () => object | undefined;
|
||||
getWatermarkForegroundConfigForBrowser: () => object | undefined;
|
||||
getLicenseDetails: (licenseKey: string) => object;
|
||||
}
|
||||
interface EnterpriseRegistryOptions {
|
||||
styles?: string;
|
||||
licenseManager?: (options: AgChartOptions) => LicenseManager;
|
||||
injectWatermark?: (domManager: any, text: string) => void;
|
||||
createBackground?: (ctx: any) => any;
|
||||
createForeground?: (ctx: any) => any;
|
||||
}
|
||||
export declare const enterpriseRegistry: EnterpriseRegistryOptions;
|
||||
export {};
|
||||
97
node_modules/ag-charts-core/dist/types/src/modules/moduleDefinition.d.ts
generated
vendored
Executable file
97
node_modules/ag-charts-core/dist/types/src/modules/moduleDefinition.d.ts
generated
vendored
Executable file
@@ -0,0 +1,97 @@
|
||||
import type { DatumDefault, ExtensibleTheme, SeriesDefaultAxes, SeriesPredictAxis, SeriesType } from 'ag-charts-types';
|
||||
import type { OptionsDefs, ValidationResult } from '../state/validation';
|
||||
import type { ScaleType } from '../types/scales';
|
||||
import type { Point } from '../types/scene';
|
||||
export declare enum ModuleType {
|
||||
Chart = "chart",
|
||||
Axis = "axis",
|
||||
Series = "series",
|
||||
Plugin = "plugin",
|
||||
AxisPlugin = "axis:plugin",
|
||||
SeriesPlugin = "series:plugin",
|
||||
Preset = "preset"
|
||||
}
|
||||
export type ModuleTypeSwitch<TModule extends ModuleType, TOptions = any> = TModule extends ModuleType.Chart ? ChartModuleDefinition<TOptions> : TModule extends ModuleType.Axis ? AxisModuleDefinition<TOptions> : TModule extends ModuleType.Series ? SeriesModuleDefinition<TOptions> : TModule extends ModuleType.Preset ? PresetModuleDefinition<TOptions> : TModule extends ModuleType.Plugin ? PluginModuleDefinition<TOptions> : TModule extends ModuleType.AxisPlugin ? AxisPluginModuleDefinition<TOptions> : TModule extends ModuleType.SeriesPlugin ? SeriesPluginModuleDefinition<TOptions> : never;
|
||||
export interface ModuleInstance {
|
||||
destroy?(this: void): void;
|
||||
}
|
||||
export interface SeriesModuleInstance extends ModuleInstance {
|
||||
}
|
||||
export interface PluginModuleInstance extends ModuleInstance {
|
||||
enabled?: boolean;
|
||||
processData?(dataController: any): Promise<void> | void;
|
||||
}
|
||||
export type PickNodeDatumResult = {
|
||||
datum: NonNullable<any>;
|
||||
distanceSquared: number;
|
||||
} | undefined;
|
||||
export interface PropertyDefinitionOpts {
|
||||
isContinuousX: boolean;
|
||||
isContinuousY: boolean;
|
||||
xScaleType?: ScaleType;
|
||||
yScaleType?: ScaleType;
|
||||
}
|
||||
export interface SeriesPluginModuleInstance extends ModuleInstance {
|
||||
pickNodeExact(point: Point): PickNodeDatumResult;
|
||||
pickNodeNearest(point: Point): PickNodeDatumResult;
|
||||
pickNodeMainAxisFirst(point: Point, majorDirection: any): PickNodeDatumResult | undefined;
|
||||
getPropertyDefinitions(opts: PropertyDefinitionOpts): any[];
|
||||
getDomain(direction: any): any[];
|
||||
getTooltipParams(): object;
|
||||
}
|
||||
export interface ModuleDefinition<TModule extends ModuleType = ModuleType, TOptions = any, TInstance extends ModuleInstance = ModuleInstance> {
|
||||
readonly type: `${TModule}` | TModule;
|
||||
readonly name: string;
|
||||
readonly version: string;
|
||||
readonly enterprise?: boolean;
|
||||
readonly dependencies?: ModuleDefinition[];
|
||||
readonly placeholder?: boolean;
|
||||
options?: OptionsDefs<TOptions>;
|
||||
themeTemplate?: ExtensibleTheme<any>;
|
||||
style?: string;
|
||||
create(this: void, ...args: any[]): TInstance;
|
||||
validate?(this: void, options: unknown, optionsDefs: OptionsDefs<TOptions>, path: string): ValidationResult<TOptions>;
|
||||
}
|
||||
export interface ChartModuleDefinition<TOptions> extends ModuleDefinition<ModuleType.Chart, TOptions> {
|
||||
options: OptionsDefs<TOptions>;
|
||||
}
|
||||
export interface PresetModuleDefinition<TOptions> extends ModuleDefinition<ModuleType.Preset, TOptions> {
|
||||
options: OptionsDefs<TOptions>;
|
||||
create(this: void, options: unknown, ...args: any[]): any;
|
||||
processData?(this: void, data: unknown): {
|
||||
data?: unknown[];
|
||||
series?: Array<{
|
||||
xKey: string;
|
||||
yKey: string;
|
||||
}>;
|
||||
};
|
||||
}
|
||||
export interface AxisModuleDefinition<TOptions> extends ModuleDefinition<ModuleType.Axis, TOptions> {
|
||||
readonly chartType: string;
|
||||
options: OptionsDefs<TOptions>;
|
||||
}
|
||||
export interface SeriesModuleDefinition<TOptions> extends ModuleDefinition<ModuleType.Series, TOptions, SeriesModuleInstance> {
|
||||
readonly chartType: string;
|
||||
readonly groupable?: boolean;
|
||||
readonly stackable?: boolean;
|
||||
readonly stackedByDefault?: boolean;
|
||||
readonly solo?: boolean;
|
||||
predictAxis?: (direction: any, datum: DatumDefault, seriesOptions: any) => SeriesPredictAxis<SeriesType> | undefined;
|
||||
defaultAxes?: SeriesDefaultAxes<SeriesType>;
|
||||
axisKeys?: Partial<Record<string, string>>;
|
||||
axisKeysFlipped?: Partial<Record<string, string>>;
|
||||
matchingKeys?: string[];
|
||||
options: OptionsDefs<TOptions>;
|
||||
}
|
||||
export interface PluginModuleDefinition<TOptions> extends ModuleDefinition<ModuleType.Plugin, TOptions> {
|
||||
readonly chartType?: string;
|
||||
patchContext?(this: void, ctx: any): void;
|
||||
}
|
||||
export interface AxisPluginModuleDefinition<TOptions> extends ModuleDefinition<ModuleType.AxisPlugin, TOptions> {
|
||||
readonly chartType?: string;
|
||||
readonly axisTypes?: string[];
|
||||
}
|
||||
export interface SeriesPluginModuleDefinition<TOptions> extends ModuleDefinition<ModuleType.SeriesPlugin, TOptions, SeriesPluginModuleInstance> {
|
||||
readonly chartType?: string;
|
||||
readonly seriesTypes?: string[];
|
||||
}
|
||||
6
node_modules/ag-charts-core/dist/types/src/modules/moduleInstance.d.ts
generated
vendored
Executable file
6
node_modules/ag-charts-core/dist/types/src/modules/moduleInstance.d.ts
generated
vendored
Executable file
@@ -0,0 +1,6 @@
|
||||
import { CleanupRegistry } from '../state/cleanupRegistry';
|
||||
import type { ModuleInstance } from './moduleDefinition';
|
||||
export declare abstract class AbstractModuleInstance implements ModuleInstance {
|
||||
protected readonly cleanup: CleanupRegistry;
|
||||
destroy(): void;
|
||||
}
|
||||
21
node_modules/ag-charts-core/dist/types/src/modules/moduleRegistry.d.ts
generated
vendored
Executable file
21
node_modules/ag-charts-core/dist/types/src/modules/moduleRegistry.d.ts
generated
vendored
Executable file
@@ -0,0 +1,21 @@
|
||||
import { type AxisModuleDefinition, type AxisPluginModuleDefinition, type ChartModuleDefinition, type ModuleDefinition, ModuleType, type ModuleTypeSwitch, type PluginModuleDefinition, type PresetModuleDefinition, type SeriesModuleDefinition, type SeriesPluginModuleDefinition } from './moduleDefinition';
|
||||
export declare enum RegistryMode {
|
||||
Enterprise = "enterprise",
|
||||
Integrated = "integrated",
|
||||
UMD = "umd"
|
||||
}
|
||||
export declare function register(def: ModuleDefinition | ChartModuleDefinition<any> | AxisModuleDefinition<any> | SeriesModuleDefinition<any> | PresetModuleDefinition<any> | PluginModuleDefinition<any> | AxisPluginModuleDefinition<any> | SeriesPluginModuleDefinition<any>): void;
|
||||
export declare function registerModules(definitions: Array<ModuleDefinition | ModuleDefinition[]>): void;
|
||||
export declare function reset(): void;
|
||||
export declare function hasModule(moduleName: string): boolean;
|
||||
export declare function listModules(): Generator<ModuleDefinition>;
|
||||
export declare function listModulesByType<T extends ModuleType>(moduleType: T): Generator<ModuleTypeSwitch<T>>;
|
||||
export declare function getAxisModule(moduleName: string): AxisModuleDefinition<any> | undefined;
|
||||
export declare function getChartModule(moduleName: string): ChartModuleDefinition<any>;
|
||||
export declare function getPresetModule(moduleName: string): PresetModuleDefinition<any> | undefined;
|
||||
export declare function getSeriesModule(moduleName: string): SeriesModuleDefinition<any> | undefined;
|
||||
export declare function setRegistryMode(registryFlag: RegistryMode): void;
|
||||
export declare function isEnterprise(): boolean;
|
||||
export declare function isIntegrated(): boolean;
|
||||
export declare function isUmd(): boolean;
|
||||
export declare function isModuleType<T extends ModuleType>(moduleType: T, definition: ModuleDefinition | undefined): definition is ModuleTypeSwitch<T>;
|
||||
39
node_modules/ag-charts-core/dist/types/src/rendering/changeDetectable.d.ts
generated
vendored
Executable file
39
node_modules/ag-charts-core/dist/types/src/rendering/changeDetectable.d.ts
generated
vendored
Executable file
@@ -0,0 +1,39 @@
|
||||
type Target = {
|
||||
[K in string]: any;
|
||||
} & {
|
||||
onChangeDetection(privateKey: string): void;
|
||||
};
|
||||
interface SceneChangeDetectionOptions<T = any> {
|
||||
convertor?: (o: any) => any;
|
||||
changeCb?: (o: T) => any;
|
||||
checkDirtyOnAssignment?: boolean;
|
||||
equals?: (newValue: T, oldValue: T) => boolean;
|
||||
}
|
||||
interface SceneObjectChangeDetectionOptions<T = any> {
|
||||
convertor?: (o: any) => any;
|
||||
changeCb?: (o: T) => any;
|
||||
checkDirtyOnAssignment?: boolean;
|
||||
equals: (newValue: T, oldValue: T) => boolean;
|
||||
}
|
||||
interface SceneArrayChangeDetectionOptions<T = any> {
|
||||
convertor?: (o: any) => any;
|
||||
changeCb?: (o: T) => any;
|
||||
checkDirtyOnAssignment?: boolean;
|
||||
equals?: never;
|
||||
}
|
||||
export declare const TRIPLE_EQ: (lhs: unknown, rhs: unknown) => boolean;
|
||||
export declare function SceneChangeDetection<T extends Target = any>(opts?: SceneChangeDetectionOptions): (target: T, key: string) => void;
|
||||
export declare function SceneRefChangeDetection<T extends Target = any>(opts?: SceneChangeDetectionOptions): (target: T, key: string) => void;
|
||||
export declare function SceneObjectChangeDetection<T extends Target = any>(opts: SceneObjectChangeDetectionOptions): (target: T, key: string) => void;
|
||||
export declare function SceneArrayChangeDetection<T extends Target = any>(opts?: SceneArrayChangeDetectionOptions): (target: T, key: string) => void;
|
||||
export declare function DeclaredSceneChangeDetection<V>(opts?: SceneChangeDetectionOptions): <K extends string, T extends {
|
||||
[x: string]: any;
|
||||
} & {
|
||||
onChangeDetection(privateKey: string): void;
|
||||
} & { [P in `__${K}`]: V; }>(target: T, key: K) => void;
|
||||
export declare function DeclaredSceneObjectChangeDetection<V>(opts?: SceneObjectChangeDetectionOptions): <K extends string, T extends {
|
||||
[x: string]: any;
|
||||
} & {
|
||||
onChangeDetection(privateKey: string): void;
|
||||
} & { [P in `__${K}`]: V; }>(target: T, key: K) => void;
|
||||
export {};
|
||||
11
node_modules/ag-charts-core/dist/types/src/rendering/changeDetectableProperties.d.ts
generated
vendored
Executable file
11
node_modules/ag-charts-core/dist/types/src/rendering/changeDetectableProperties.d.ts
generated
vendored
Executable file
@@ -0,0 +1,11 @@
|
||||
import { BaseProperties } from '../state/properties';
|
||||
export declare class ChangeDetectableProperties extends BaseProperties {
|
||||
protected _dirty: boolean;
|
||||
protected markDirty(): void;
|
||||
markClean(_opts?: {
|
||||
force?: boolean;
|
||||
recursive?: boolean;
|
||||
}): void;
|
||||
isDirty(): boolean;
|
||||
onChangeDetection(_property: string): void;
|
||||
}
|
||||
47
node_modules/ag-charts-core/dist/types/src/rendering/domElements.d.ts
generated
vendored
Executable file
47
node_modules/ag-charts-core/dist/types/src/rendering/domElements.d.ts
generated
vendored
Executable file
@@ -0,0 +1,47 @@
|
||||
import type { AgIconName } from 'ag-charts-types';
|
||||
import { type AttributeSet, type InputAttributeSet } from '../utils/dom/attributeUtil';
|
||||
type LabelAndIcon = {
|
||||
label: string;
|
||||
icon?: AgIconName;
|
||||
};
|
||||
type IconOnly = {
|
||||
label?: never;
|
||||
icon: AgIconName;
|
||||
altText: string;
|
||||
};
|
||||
export type LabelIcon = LabelAndIcon | IconOnly;
|
||||
export type ButtonOptions = LabelIcon & {
|
||||
onPress: (event: MouseEvent) => void;
|
||||
};
|
||||
export declare function createButton(options: ButtonOptions, attrs?: AttributeSet): HTMLButtonElement & HTMLElement & {
|
||||
id: import("../main").ElementID;
|
||||
};
|
||||
export interface CheckboxOptions {
|
||||
checked: boolean;
|
||||
onChange: (checked: boolean, event: Event) => void;
|
||||
}
|
||||
export declare function createCheckbox(options: CheckboxOptions, attrs?: AttributeSet): HTMLInputElement & HTMLElement & {
|
||||
id: import("../main").ElementID;
|
||||
};
|
||||
export interface SelectOptions {
|
||||
options: Array<{
|
||||
label: string;
|
||||
value: string;
|
||||
}>;
|
||||
value: string;
|
||||
onChange: (value: string, event: Event) => void;
|
||||
}
|
||||
export declare function createSelect(options: SelectOptions, attrs?: AttributeSet): HTMLSelectElement & HTMLElement & {
|
||||
id: import("../main").ElementID;
|
||||
};
|
||||
export interface TextAreaOptions {
|
||||
value: string;
|
||||
onChange: (value: string, event: Event) => void;
|
||||
}
|
||||
export declare function createTextArea(options: TextAreaOptions, attrs?: InputAttributeSet): HTMLTextAreaElement & HTMLElement & {
|
||||
id: import("../main").ElementID;
|
||||
};
|
||||
export declare function createIcon(icon?: AgIconName): HTMLSpanElement & HTMLElement & {
|
||||
id: import("../main").ElementID;
|
||||
};
|
||||
export {};
|
||||
8
node_modules/ag-charts-core/dist/types/src/rendering/easing.d.ts
generated
vendored
Executable file
8
node_modules/ag-charts-core/dist/types/src/rendering/easing.d.ts
generated
vendored
Executable file
@@ -0,0 +1,8 @@
|
||||
export declare const linear: (n: number) => number;
|
||||
export declare const easeIn: (n: number) => number;
|
||||
export declare const easeOut: (n: number) => number;
|
||||
export declare const easeInOut: (n: number) => number;
|
||||
export declare const easeInQuad: (n: number) => number;
|
||||
export declare const easeOutQuad: (n: number) => number;
|
||||
export declare const easeInOutQuad: (n: number) => number;
|
||||
export declare const inverseEaseOut: (x: number) => number;
|
||||
22
node_modules/ag-charts-core/dist/types/src/rendering/textMeasurer.d.ts
generated
vendored
Executable file
22
node_modules/ag-charts-core/dist/types/src/rendering/textMeasurer.d.ts
generated
vendored
Executable file
@@ -0,0 +1,22 @@
|
||||
import type { TextSegment } from 'ag-charts-types';
|
||||
import { type FontOptions, type ITextMeasurer, type LegacyTextMetrics, type MultilineSegmentsMetricsBox, type MultilineTextMetricsBox, type TextMetricsBox } from '../types/text';
|
||||
export declare class TextMeasurer implements ITextMeasurer {
|
||||
private readonly ctx;
|
||||
private readonly measureTextCached?;
|
||||
private readonly baselineMap;
|
||||
private readonly charMap;
|
||||
private lineHeightCache;
|
||||
constructor(ctx: CanvasRenderingContext2D, measureTextCached?: ((text: string, useCache?: boolean) => LegacyTextMetrics) | undefined);
|
||||
baselineDistance(textBaseline: CanvasTextBaseline): number;
|
||||
lineHeight(): number;
|
||||
measureText(text: string): TextMetricsBox;
|
||||
measureLines(text: string | string[]): MultilineTextMetricsBox;
|
||||
textWidth(text: string, estimate?: boolean): number;
|
||||
private charWidth;
|
||||
}
|
||||
export declare function cachedTextMeasurer(font: string | FontOptions): TextMeasurer;
|
||||
export declare namespace cachedTextMeasurer {
|
||||
var clear: () => void;
|
||||
}
|
||||
export declare function measureTextSegments(textSegments: TextSegment[], defaultFont: FontOptions): MultilineSegmentsMetricsBox;
|
||||
export type { ITextMeasurer, LineMetricsBox, MeasuredSegment, MultilineSegmentsMetricsBox, MultilineTextMetricsBox, SegmentsLineMetrics, TextMetricsBox, } from '../types/text';
|
||||
14
node_modules/ag-charts-core/dist/types/src/state/caching.d.ts
generated
vendored
Executable file
14
node_modules/ag-charts-core/dist/types/src/state/caching.d.ts
generated
vendored
Executable file
@@ -0,0 +1,14 @@
|
||||
export declare class SimpleCache<T> {
|
||||
protected readonly getter: () => T;
|
||||
protected result?: T;
|
||||
constructor(getter: () => T);
|
||||
get(): T;
|
||||
clear(): void;
|
||||
}
|
||||
export declare class WeakCache<T extends WeakKey> {
|
||||
protected readonly getter: () => T;
|
||||
protected result?: WeakRef<T>;
|
||||
constructor(getter: () => T);
|
||||
get(): T;
|
||||
clear(): void;
|
||||
}
|
||||
13
node_modules/ag-charts-core/dist/types/src/state/callbackCache.d.ts
generated
vendored
Executable file
13
node_modules/ag-charts-core/dist/types/src/state/callbackCache.d.ts
generated
vendored
Executable file
@@ -0,0 +1,13 @@
|
||||
import type { Callback, CallbackParam, RequireOptional } from '../types/global';
|
||||
type Caller = {
|
||||
context?: unknown;
|
||||
} | undefined;
|
||||
export type CallbackParamRules<P> = RequireOptional<Omit<P, 'context'>>;
|
||||
export declare function callWithContext<F extends Callback>(callers: Caller | Caller[], fn: F, params: CallbackParam<F>): ReturnType<F>;
|
||||
export declare class CallbackCache {
|
||||
private cache;
|
||||
call<F extends Callback>(callers: Caller | Caller[], fn: F, params: CallbackParam<F>): ReturnType<F> | undefined;
|
||||
private invoke;
|
||||
invalidateCache(): void;
|
||||
}
|
||||
export {};
|
||||
9
node_modules/ag-charts-core/dist/types/src/state/cleanupRegistry.d.ts
generated
vendored
Executable file
9
node_modules/ag-charts-core/dist/types/src/state/cleanupRegistry.d.ts
generated
vendored
Executable file
@@ -0,0 +1,9 @@
|
||||
import type { AnyFn } from '../types/global';
|
||||
type RegisteredCallback = AnyFn | false | null | undefined;
|
||||
export declare class CleanupRegistry {
|
||||
protected readonly callbacks: Set<AnyFn>;
|
||||
flush(): void;
|
||||
merge(registry: CleanupRegistry): void;
|
||||
register(...callbacks: RegisteredCallback[]): void;
|
||||
}
|
||||
export {};
|
||||
29
node_modules/ag-charts-core/dist/types/src/state/memento.d.ts
generated
vendored
Executable file
29
node_modules/ag-charts-core/dist/types/src/state/memento.d.ts
generated
vendored
Executable file
@@ -0,0 +1,29 @@
|
||||
export interface MementoOriginator<Memento = any> {
|
||||
mementoOriginatorKey: string;
|
||||
createMemento(): Memento;
|
||||
guardMemento(blob: unknown, messages: Array<string>): blob is Memento | undefined;
|
||||
restoreMemento(version: string, mementoVersion: string, blob: Memento | undefined): void;
|
||||
}
|
||||
type MementoCaretakerPacket = Record<'version', string> & Record<string, any>;
|
||||
/**
|
||||
* The caretaker manages the encoding and decoding of mementos from originators, ensuring they can be provided to and
|
||||
* received from external systems. A memento encapsulates the state of an originator at a point in time. A memento
|
||||
* is also versioned to ensure it can be migrated to newer versions of the originator.
|
||||
*/
|
||||
export declare class MementoCaretaker {
|
||||
readonly version: string;
|
||||
constructor(version: string);
|
||||
save(...originators: Array<MementoOriginator>): MementoCaretakerPacket;
|
||||
restore(blob: unknown, ...originators: Array<MementoOriginator>): void;
|
||||
/**
|
||||
* Encode a memento as a serializable object, encoding any non-serializble types.
|
||||
*/
|
||||
private encode;
|
||||
/**
|
||||
* Decode an encoded memento, decoding any non-serializable types.
|
||||
*/
|
||||
private decode;
|
||||
private static encodeTypes;
|
||||
private static decodeTypes;
|
||||
}
|
||||
export {};
|
||||
6
node_modules/ag-charts-core/dist/types/src/state/memo.d.ts
generated
vendored
Executable file
6
node_modules/ag-charts-core/dist/types/src/state/memo.d.ts
generated
vendored
Executable file
@@ -0,0 +1,6 @@
|
||||
import type { AnyFn } from '../types/global';
|
||||
export declare function memo<T, R>(params: T, fnGenerator: (params: T) => R): R;
|
||||
export declare function simpleMemorize2<F extends AnyFn>(fn: F, cacheCallback?: (type: 'hit' | 'miss', fn: F, keys: any[]) => void): F & {
|
||||
reset: () => void;
|
||||
};
|
||||
export declare function simpleMemorize<F extends AnyFn>(fn: F, cacheCallback?: (type: 'hit' | 'miss', fn: F, keys: any[]) => void): (...p: Parameters<F>) => ReturnType<F>;
|
||||
15
node_modules/ag-charts-core/dist/types/src/state/properties.d.ts
generated
vendored
Executable file
15
node_modules/ag-charts-core/dist/types/src/state/properties.d.ts
generated
vendored
Executable file
@@ -0,0 +1,15 @@
|
||||
export { addFakeTransformToInstanceProperty as Property } from '../utils/types/decorator';
|
||||
export declare class BaseProperties<T extends object = object> {
|
||||
handleUnknownProperties(_unknownKeys: Set<unknown>, _properties: T): void;
|
||||
set(properties: T): this;
|
||||
clear(): this;
|
||||
toJson<J>(this: J): T;
|
||||
}
|
||||
export declare class PropertiesArray<T extends BaseProperties> extends Array<T> {
|
||||
private readonly itemFactory;
|
||||
constructor(itemFactory: (new () => T) | ((params: any) => T), ...properties: object[]);
|
||||
set(properties: object[]): this;
|
||||
reset(properties: object[]): PropertiesArray<T> | undefined;
|
||||
toJson(): object[];
|
||||
}
|
||||
export declare function isProperties<T extends object>(value: unknown): value is BaseProperties<T>;
|
||||
20
node_modules/ag-charts-core/dist/types/src/state/proxy.d.ts
generated
vendored
Executable file
20
node_modules/ag-charts-core/dist/types/src/state/proxy.d.ts
generated
vendored
Executable file
@@ -0,0 +1,20 @@
|
||||
export declare function ProxyProperty(proxyPath: string | string[], configMetadata?: {
|
||||
optional?: boolean;
|
||||
}): PropertyDecorator;
|
||||
export declare function ProxyOnWrite(proxyProperty: string): PropertyDecorator;
|
||||
export declare function ProxyPropertyOnWrite(childName: string, childProperty?: string): PropertyDecorator;
|
||||
export interface ActionOnSetOptions<T, V = any> {
|
||||
newValue?: (this: T, newValue: V) => void;
|
||||
oldValue?: (this: T, oldValue: V) => void;
|
||||
changeValue?: (this: T, newValue?: V, oldValue?: V) => void;
|
||||
}
|
||||
/**
|
||||
* Allows side-effects to be triggered on property write.
|
||||
*
|
||||
* @param opts.newValue called when a new value is set - never called for undefined values.
|
||||
* @param opts.oldValue called with the old value before a new value is set - never called for
|
||||
* undefined values.
|
||||
* @param opts.changeValue called on any change to the value - always called.
|
||||
*/
|
||||
export declare function ActionOnSet<T, V = any>(opts: ActionOnSetOptions<T, V>): PropertyDecorator;
|
||||
export declare function ObserveChanges<T, V = any>(observerFn: (target: T, newValue?: V, oldValue?: V) => void): PropertyDecorator;
|
||||
56
node_modules/ag-charts-core/dist/types/src/state/stateMachine.d.ts
generated
vendored
Executable file
56
node_modules/ag-charts-core/dist/types/src/state/stateMachine.d.ts
generated
vendored
Executable file
@@ -0,0 +1,56 @@
|
||||
import * as Debug from '../logging/debugLogger';
|
||||
type StateDefinition<State extends string, Events extends Record<string, any>> = {
|
||||
[key in keyof Events]?: Destination<State, Events[key]>;
|
||||
};
|
||||
type Destination<State extends string, Data> = Array<StateTransition<State, Data>> | StateTransition<State, Data> | StateTransitionAction<Data> | State | HierarchyState | StateMachine<any, any>;
|
||||
type StateUtils<State extends string> = {
|
||||
onEnter?: (from?: State, data?: any) => void;
|
||||
onExit?: () => void;
|
||||
};
|
||||
type StateTransition<State, Data> = {
|
||||
/**
|
||||
* Return `false` to prevent the action and transition. The FSM will pick the first transition that passes its
|
||||
* guard or does not have one.
|
||||
*/
|
||||
guard?: (data: Data) => boolean;
|
||||
target?: State | HierarchyState | StateMachine<any, any>;
|
||||
action?: StateTransitionAction<Data>;
|
||||
};
|
||||
type StateTransitionAction<Data> = (data: Data) => void;
|
||||
type HierarchyState = '__parent' | '__child';
|
||||
export declare function StateMachineProperty(): PropertyDecorator;
|
||||
declare abstract class AbstractStateMachine<Events extends Record<string, any>> {
|
||||
parent?: AbstractStateMachine<Events>;
|
||||
abstract transition<Event extends keyof Events & string>(event: Event, data?: Events[Event]): void;
|
||||
abstract transitionAsync<Event extends keyof Events & string>(event: Event, data?: Events[Event]): void;
|
||||
transitionRoot<Event extends keyof Events & string>(event: Event, data?: Events[Event]): void;
|
||||
}
|
||||
/**
|
||||
* A Hierarchical Finite State Machine is a system that must be in exactly one of a list of states, where those states
|
||||
* can also be other state machines. It can only transition between one state and another if a transition event is
|
||||
* provided between the two states.
|
||||
*/
|
||||
export declare class StateMachine<State extends string, Events extends Record<string, any>> extends AbstractStateMachine<Events> {
|
||||
private readonly defaultState;
|
||||
private readonly states;
|
||||
private readonly enterEach?;
|
||||
static readonly child: "__child";
|
||||
static readonly parent: "__parent";
|
||||
protected readonly debug: Debug.DebugLogger;
|
||||
private state;
|
||||
private childState?;
|
||||
constructor(defaultState: State, states: Record<State, StateDefinition<State, Events> & StateUtils<State>>, enterEach?: ((from: State | HierarchyState, to: State | HierarchyState) => void) | undefined);
|
||||
transition<Event extends keyof Events & string>(event: Event, data?: Events[Event]): void;
|
||||
transitionAsync<Event extends keyof Events & string>(event: Event, data?: Events[Event]): void;
|
||||
protected is(value: unknown): boolean;
|
||||
protected resetHierarchy(): void;
|
||||
private transitionChild;
|
||||
private getDestinationState;
|
||||
}
|
||||
export declare class ParallelStateMachine<State extends string, Events extends Record<string, any>> extends AbstractStateMachine<Events> {
|
||||
private readonly stateMachines;
|
||||
constructor(...stateMachines: Array<StateMachine<State, Events>>);
|
||||
transition<Event extends keyof Events & string>(event: Event, data?: Events[Event]): void;
|
||||
transitionAsync<Event extends keyof Events & string>(event: Event, data?: Events[Event]): void;
|
||||
}
|
||||
export {};
|
||||
175
node_modules/ag-charts-core/dist/types/src/state/validation.d.ts
generated
vendored
Executable file
175
node_modules/ag-charts-core/dist/types/src/state/validation.d.ts
generated
vendored
Executable file
@@ -0,0 +1,175 @@
|
||||
import type { AreExact, IsUnion } from '../types/global';
|
||||
declare const descriptionSymbol: unique symbol;
|
||||
declare const requiredSymbol: unique symbol;
|
||||
declare const undocumentedSymbol: unique symbol;
|
||||
export declare const unionSymbol: unique symbol;
|
||||
type ObjectLikeDef<T> = IsUnion<NonNullable<T>> extends true ? OptionsDefs<Exclude<T, undefined>> : T extends object ? keyof T extends never ? never : OptionsDefs<T> : never;
|
||||
type Singular<T> = T extends any[] ? T[number] : T;
|
||||
type PrivateSymbols = {
|
||||
[descriptionSymbol]?: string;
|
||||
[requiredSymbol]?: boolean;
|
||||
[undocumentedSymbol]?: boolean;
|
||||
[unionSymbol]?: string;
|
||||
};
|
||||
export type OptionsDefs<T> = {
|
||||
[K in keyof Singular<T>]-?: Validator | ObjectLikeDef<Singular<T>[K]>;
|
||||
} & PrivateSymbols;
|
||||
export type TypeUnionDefs<T, K extends string | number | symbol> = {
|
||||
[P in K]: OptionsDefs<Omit<Extract<T, {
|
||||
type: P;
|
||||
}>, 'type'>>;
|
||||
};
|
||||
export interface ValidationResult<T> {
|
||||
cleared: Partial<T> | null;
|
||||
invalid: ValidationError[];
|
||||
}
|
||||
export interface ValidatorResult extends ValidationResult<any> {
|
||||
valid: boolean;
|
||||
}
|
||||
export interface ValidatorContext {
|
||||
path: string;
|
||||
options: any;
|
||||
}
|
||||
export declare enum ErrorType {
|
||||
Invalid = "invalid",
|
||||
Required = "required",
|
||||
Unknown = "unknown"
|
||||
}
|
||||
export interface Validator extends Function, PrivateSymbols {
|
||||
(value: unknown, context: ValidatorContext): ValidatorResult | boolean;
|
||||
}
|
||||
export declare class ValidationError {
|
||||
readonly type: ErrorType | `${ErrorType}`;
|
||||
readonly description: string | undefined;
|
||||
readonly value: any;
|
||||
readonly path: string;
|
||||
readonly key?: string | undefined;
|
||||
protected altPath?: string;
|
||||
constructor(type: ErrorType | `${ErrorType}`, description: string | undefined, value: any, path: string, key?: string | undefined);
|
||||
setUnionType(unionType: string, path: string): void;
|
||||
getPrefix(): string;
|
||||
toString(): string;
|
||||
}
|
||||
export declare class UnknownError extends ValidationError {
|
||||
suggestions: string[];
|
||||
key: string;
|
||||
constructor(suggestions: string[], value: unknown, path: string, key: string);
|
||||
getPrefix(): string;
|
||||
getPostfix(): string;
|
||||
toString(): string;
|
||||
}
|
||||
/**
|
||||
* Validates the provided options against the specified definitions.
|
||||
* @param options The options object to validate.
|
||||
* @param optionsDefs The definitions against which to validate the options.
|
||||
* @param path The current path in the options object, for nested properties.
|
||||
* @returns An object containing valid options and validation errors.
|
||||
*/
|
||||
export declare function validate<T>(options: unknown, optionsDefs: OptionsDefs<T>, path?: string): ValidationResult<T>;
|
||||
/**
|
||||
* Attaches a descriptive message to a validator function.
|
||||
* @param validator The validator function to which to attach a description.
|
||||
* @param description The description to attach.
|
||||
* @returns A new validator function with the attached description.
|
||||
*/
|
||||
export declare function attachDescription(validator: Validator, description: string): Validator;
|
||||
export declare function attachDescription<T>(optionsDefs: OptionsDefs<T>, description: string): OptionsDefs<T>;
|
||||
/**
|
||||
* Marks a validator or option definitions object as required.
|
||||
* @param validatorOrDefs The validator or option definitions to mark as required.
|
||||
* @returns The modified validator or option definitions, marked as required.
|
||||
*/
|
||||
export declare function required<T extends OptionsDefs<any>>(validatorOrDefs: T): T;
|
||||
export declare function required<T extends OptionsDefs<any>[]>(validatorOrDefs: T): T;
|
||||
export declare function required(validatorOrDefs: Validator): Validator;
|
||||
export declare function undocumented(validatorOrDefs: Validator): Validator;
|
||||
export declare function undocumented<T extends OptionsDefs<any>>(validatorOrDefs: T): T;
|
||||
/**
|
||||
* Creates a validator for ensuring an object matches the provided option definitions.
|
||||
* @param defs The option definitions against which to validate an object.
|
||||
* @param description (Optional) A description for the validator, defaulting to 'an object'.
|
||||
* @returns A validator function for the given option definitions.
|
||||
*/
|
||||
export declare const optionsDefs: <T>(defs: OptionsDefs<T>, description?: string, failAll?: boolean) => Validator;
|
||||
export declare const typeUnion: <T extends {
|
||||
type: string;
|
||||
}>(defs: TypeUnionDefs<T, T['type']>, description: string, defaultType?: T['type']) => OptionsDefs<T>;
|
||||
/**
|
||||
* Combines multiple validators, requiring all to pass.
|
||||
* @param validators An array of validators to combine.
|
||||
* @returns A validator that requires all specified validators to pass.
|
||||
*/
|
||||
export declare const and: (...validators: Validator[]) => Validator;
|
||||
/**
|
||||
* Combines multiple validators, passing if any one of them does.
|
||||
* @param validators An array of validators to combine.
|
||||
* @returns A validator that passes if any one of the specified validators does.
|
||||
*/
|
||||
export declare const or: (...validators: Validator[]) => Validator;
|
||||
export declare const array: Validator;
|
||||
export declare const boolean: Validator;
|
||||
export declare const callback: Validator;
|
||||
export declare const color: Validator;
|
||||
export declare const date: Validator;
|
||||
export declare const defined: Validator;
|
||||
export declare const number: Validator;
|
||||
export declare const object: Validator;
|
||||
export declare const string: Validator;
|
||||
export declare const htmlElement: Validator;
|
||||
export declare const arrayLength: (minLength: number, maxLength?: number) => Validator;
|
||||
export declare const stringLength: (minLength: number, maxLength?: number) => Validator;
|
||||
export declare const numberMin: (min: number, inclusive?: boolean) => Validator;
|
||||
export declare const numberRange: (min: number, max: number) => Validator;
|
||||
export declare const positiveNumber: Validator;
|
||||
export declare const positiveNumberNonZero: Validator;
|
||||
export declare const ratio: Validator;
|
||||
export declare const lessThan: (otherField: string) => Validator;
|
||||
export declare const lessThanOrEqual: (otherField: string) => Validator;
|
||||
export declare const greaterThan: (otherField: string) => Validator;
|
||||
/**
|
||||
* Creates a validator for a union of allowed values.
|
||||
* @param allowed An array of allowed values.
|
||||
* @returns A validator function that checks if a value is among the allowed ones.
|
||||
*/
|
||||
export declare function union(allowed: object): Validator;
|
||||
export declare function union(...allowed: any[]): Validator;
|
||||
/**
|
||||
* A defensive version of `union` that intentionally breaks compilation if a string union type is changed.
|
||||
* @example
|
||||
* type U = 'a' | 'b';
|
||||
* strictUnion<U>()('a', 'b'); // compilation breaks if U is changed to `'a' | 'b' | 'c'`.
|
||||
*/
|
||||
export declare function strictUnion<T extends string>(): <U extends readonly T[]>(...args: U & (AreExact<T, U[number]> extends true ? U : never)) => Validator;
|
||||
/**
|
||||
* Creates a validator for a single constant value.
|
||||
* @param allowed The allowed constant value.
|
||||
* @returns A validator function that checks for equality with the allowed value.
|
||||
*/
|
||||
export declare const constant: (allowed: boolean | number | string) => Validator;
|
||||
/**
|
||||
* Creates a validator for instances of a specific class.
|
||||
* @param instanceType The constructor of the class to check instances against.
|
||||
* @param description An optional description string.
|
||||
* @returns A validator function that checks if a value is an instance of the specified class.
|
||||
*/
|
||||
export declare const instanceOf: (instanceType: Function, description?: string) => Validator;
|
||||
/**
|
||||
* Creates a validator for arrays where every element must pass a given validator.
|
||||
* @param validator The validator to apply to each array element.
|
||||
* @param description An optional description string.
|
||||
* @param strict When enabled validator fails on any invalid item, otherwise invalid items are filtered.
|
||||
* @returns A validator function for arrays with elements validated by the specified validator.
|
||||
*/
|
||||
export declare const arrayOf: (validator: Validator, description?: string, strict?: boolean) => Validator;
|
||||
/**
|
||||
* Creates a validator for arrays where each element is validated against a given set of definitions.
|
||||
* Allows capturing both valid and invalid values while providing detailed validation errors.
|
||||
* @param defs The validation definitions to apply to each array element.
|
||||
* @param description An optional description string.
|
||||
* @returns A validator function for arrays, storing valid elements and collecting errors for invalid ones.
|
||||
*/
|
||||
export declare const arrayOfDefs: <T>(defs: OptionsDefs<T>, description?: string) => Validator;
|
||||
export declare const callbackOf: (validator: Validator, description?: string) => Validator;
|
||||
export declare const callbackDefs: <T>(defs: OptionsDefs<T>, description?: string) => Validator;
|
||||
export declare function hasRequiredInPath(errors: ValidationError[], rootPath: string): boolean;
|
||||
export {};
|
||||
28
node_modules/ag-charts-core/dist/types/src/structures/eventEmitter.d.ts
generated
vendored
Executable file
28
node_modules/ag-charts-core/dist/types/src/structures/eventEmitter.d.ts
generated
vendored
Executable file
@@ -0,0 +1,28 @@
|
||||
export type EventListener<T> = (event: T) => void;
|
||||
export declare class EventEmitter<EventMap extends object> {
|
||||
private readonly events;
|
||||
/**
|
||||
* Registers an event listener.
|
||||
* @param eventName The event name to listen for.
|
||||
* @param listener The callback to be invoked on the event.
|
||||
* @returns A function to unregister the listener.
|
||||
*/
|
||||
on<K extends keyof EventMap>(eventName: K, listener: EventListener<EventMap[K]>): () => void;
|
||||
/**
|
||||
* Unregisters an event listener.
|
||||
* @param eventName The event name to stop listening for.
|
||||
* @param listener The callback to be removed.
|
||||
*/
|
||||
off<K extends keyof EventMap>(eventName: K, listener: EventListener<EventMap[K]>): void;
|
||||
/**
|
||||
* Emits an event to all registered listeners.
|
||||
* @param eventName The name of the event to emit.
|
||||
* @param event The event payload.
|
||||
*/
|
||||
emit<K extends keyof EventMap>(eventName: K, event: EventMap[K]): void;
|
||||
/**
|
||||
* Clears all listeners for a specific event or all events if no event name is provided.
|
||||
* @param eventName (Optional) The name of the event to clear listeners for. If not provided, all listeners for all events are cleared.
|
||||
*/
|
||||
clear<K extends keyof EventMap>(eventName?: K): void;
|
||||
}
|
||||
42
node_modules/ag-charts-core/dist/types/src/structures/graph.d.ts
generated
vendored
Executable file
42
node_modules/ag-charts-core/dist/types/src/structures/graph.d.ts
generated
vendored
Executable file
@@ -0,0 +1,42 @@
|
||||
/**
|
||||
* A graph that is optimised for vertex lookup and adjacency by edge value.
|
||||
*/
|
||||
export declare class AdjacencyListGraph<V, E = undefined> {
|
||||
private _vertexCount;
|
||||
private _edgeCount;
|
||||
private readonly cachedNeighboursEdge?;
|
||||
private readonly processedEdge?;
|
||||
protected pendingProcessingEdgesFrom: Vertex<V>[];
|
||||
protected pendingProcessingEdgesTo: Vertex<V>[];
|
||||
private readonly singleValueEdges?;
|
||||
constructor(cachedNeighboursEdge?: E, processedEdge?: E, singleValueEdges?: Set<E>);
|
||||
clear(): void;
|
||||
getVertexCount(): number;
|
||||
getEdgeCount(): number;
|
||||
addVertex(value: V): Vertex<V>;
|
||||
addEdge(from: Vertex<V>, to: Vertex<V>, edge: E): void;
|
||||
removeVertex(vertex: Vertex<V>): void;
|
||||
removeEdge(from: Vertex<V>, to: Vertex<V>, edge: E): void;
|
||||
removeEdges(from: Vertex<V>, edgeValue: E): void;
|
||||
getVertexValue(vertex: Vertex<V>): V;
|
||||
neighbours(from: Vertex<V>): Generator<Vertex<V>, void, unknown>;
|
||||
neighboursAndEdges(from: Vertex<V, E>): Generator<[Vertex<V>, E], void, unknown>;
|
||||
neighboursWithEdgeValue(from: Vertex<V>, edgeValue: E): Vertex<V, unknown>[] | undefined;
|
||||
findNeighbour(from: Vertex<V>, edgeValue: E): Vertex<V> | undefined;
|
||||
findNeighbourValue(from: Vertex<V>, edgeValue: E): V | undefined;
|
||||
findNeighbourWithValue(from: Vertex<V>, value: V, edgeValue?: E): Vertex<V> | undefined;
|
||||
findVertexAlongEdge(from: Vertex<V>, findValues: Array<V>, edgeValue: E): Vertex<V> | undefined;
|
||||
adjacent(from: Vertex<V>, to: Vertex<V>): boolean;
|
||||
}
|
||||
/**
|
||||
* A wrapper class to ensure each vertex is unique even if the value is the same object.
|
||||
*/
|
||||
export declare class Vertex<V, E = unknown> {
|
||||
value: V;
|
||||
edges: Map<E, Vertex<V>[]>;
|
||||
private _cachedNeighbours?;
|
||||
constructor(value: V);
|
||||
readCachedNeighbours(): Map<V, Vertex<V, unknown>> | undefined;
|
||||
updateCachedNeighbours(): Map<V, Vertex<V, unknown>>;
|
||||
clear(): void;
|
||||
}
|
||||
12
node_modules/ag-charts-core/dist/types/src/structures/lruCache.d.ts
generated
vendored
Executable file
12
node_modules/ag-charts-core/dist/types/src/structures/lruCache.d.ts
generated
vendored
Executable file
@@ -0,0 +1,12 @@
|
||||
/**
|
||||
* Implements a most-recently-used caching strategy with a similar interface to Map.
|
||||
*/
|
||||
export declare class LRUCache<V, K = string> {
|
||||
private readonly maxCacheSize;
|
||||
private readonly store;
|
||||
constructor(maxCacheSize: number);
|
||||
get(key: K): NonNullable<V> | undefined;
|
||||
has(key: K): boolean;
|
||||
set(key: K, value: V): V;
|
||||
clear(): void;
|
||||
}
|
||||
2
node_modules/ag-charts-core/dist/types/src/types/animationPhase.d.ts
generated
vendored
Executable file
2
node_modules/ag-charts-core/dist/types/src/types/animationPhase.d.ts
generated
vendored
Executable file
@@ -0,0 +1,2 @@
|
||||
/** Chart animation phases - determines the top-level animation lifecycle phase for the overall chart */
|
||||
export type ChartAnimationPhase = 'initial' | 'ready' | 'disabled';
|
||||
7
node_modules/ag-charts-core/dist/types/src/types/axisDirection.d.ts
generated
vendored
Executable file
7
node_modules/ag-charts-core/dist/types/src/types/axisDirection.d.ts
generated
vendored
Executable file
@@ -0,0 +1,7 @@
|
||||
export declare enum ChartAxisDirection {
|
||||
X = "x",
|
||||
Y = "y",
|
||||
Angle = "angle",
|
||||
Radius = "radius"
|
||||
}
|
||||
export type CartesianAxisDirection = ChartAxisDirection.X | ChartAxisDirection.Y;
|
||||
47
node_modules/ag-charts-core/dist/types/src/types/geojson.d.ts
generated
vendored
Executable file
47
node_modules/ag-charts-core/dist/types/src/types/geojson.d.ts
generated
vendored
Executable file
@@ -0,0 +1,47 @@
|
||||
/** GeoJSON types based on https://datatracker.ietf.org/doc/html/rfc7946 */
|
||||
export type Position = [number, number];
|
||||
type BBox = [number, number, number, number] | [number, number, number, number, number, number];
|
||||
export type Geometry = Point | MultiPoint | LineString | MultiLineString | Polygon | MultiPolygon | GeometryCollection;
|
||||
interface GeometryCollection extends GeoJsonObject {
|
||||
type: 'GeometryCollection';
|
||||
geometries: Geometry[];
|
||||
}
|
||||
interface Point extends GeoJsonObject {
|
||||
type: 'Point';
|
||||
coordinates: Position;
|
||||
}
|
||||
interface MultiPoint extends GeoJsonObject {
|
||||
type: 'MultiPoint';
|
||||
coordinates: Position[];
|
||||
}
|
||||
interface LineString extends GeoJsonObject {
|
||||
type: 'LineString';
|
||||
coordinates: Position[];
|
||||
}
|
||||
interface MultiLineString extends GeoJsonObject {
|
||||
type: 'MultiLineString';
|
||||
coordinates: Position[][];
|
||||
}
|
||||
interface Polygon extends GeoJsonObject {
|
||||
type: 'Polygon';
|
||||
coordinates: Position[][];
|
||||
}
|
||||
interface MultiPolygon extends GeoJsonObject {
|
||||
type: 'MultiPolygon';
|
||||
coordinates: Position[][][];
|
||||
}
|
||||
interface GeoJsonObject {
|
||||
type: (Geometry | Feature | FeatureCollection)['type'];
|
||||
bbox?: BBox;
|
||||
}
|
||||
export interface Feature extends GeoJsonObject {
|
||||
type: 'Feature';
|
||||
geometry: Geometry | null;
|
||||
id?: string | number;
|
||||
properties: Record<string, any> | null;
|
||||
}
|
||||
export interface FeatureCollection extends GeoJsonObject {
|
||||
type: 'FeatureCollection';
|
||||
features: Feature[];
|
||||
}
|
||||
export {};
|
||||
62
node_modules/ag-charts-core/dist/types/src/types/global.d.ts
generated
vendored
Executable file
62
node_modules/ag-charts-core/dist/types/src/types/global.d.ts
generated
vendored
Executable file
@@ -0,0 +1,62 @@
|
||||
export type AnyFn = (...args: any[]) => any;
|
||||
export type Callback = (params: any) => any;
|
||||
export type CallbackParam<F extends Callback> = Parameters<F>[0];
|
||||
export type Nullable<T> = T | null | undefined;
|
||||
export type PlainObject = {
|
||||
[key: string | number | symbol]: any;
|
||||
};
|
||||
export type Has<P extends keyof T, T> = T & {
|
||||
[K in P]-?: T[P];
|
||||
};
|
||||
export type Mutable<T> = T extends object ? {
|
||||
-readonly [K in keyof T]: Mutable<T[K]>;
|
||||
} : T;
|
||||
export type Defined<T> = T extends undefined ? never : T;
|
||||
export type DeepRequired<T, IgnoredKeys extends string = never> = T extends AnyFn ? T : T extends any[] ? _DeepRequiredArray<T[number], IgnoredKeys> : T extends object ? _DeepRequiredObject<T, IgnoredKeys> : T;
|
||||
type _DeepRequiredArray<T, IgnoredKeys extends string> = Array<DeepRequired<Defined<T>, IgnoredKeys>>;
|
||||
type _DeepRequiredObject<T, IgnoredKeys extends string> = {
|
||||
[K in keyof T]-?: K extends IgnoredKeys ? NonNullable<T[K]> : DeepRequired<Defined<T[K]>, IgnoredKeys>;
|
||||
};
|
||||
export type DeepReadonly<T> = T extends (...args: any[]) => any ? T : T extends any[] ? _DeepReadonlyArray<T[number]> : T extends object ? _DeepReadonlyObject<T> : T;
|
||||
type _DeepReadonlyArray<T> = ReadonlyArray<DeepReadonly<T>>;
|
||||
type _DeepReadonlyObject<T> = {
|
||||
readonly [K in keyof T]: DeepReadonly<T[K]>;
|
||||
};
|
||||
export type DeepPartial<T> = T extends Array<unknown> ? T : T extends object ? {
|
||||
[K in keyof T]?: DeepPartial<T[K]>;
|
||||
} : T;
|
||||
export type PickRequired<T, K extends keyof T> = T & {
|
||||
[P in K]-?: T[P];
|
||||
};
|
||||
export type RequireOptional<T> = {
|
||||
[K in keyof Required<T>]: T[K] extends Required<T[K]> ? T[K] : T[K] | undefined;
|
||||
};
|
||||
export type Intersection<U> = (U extends any ? (k: U) => void : never) extends (k: infer I) => void ? I : never;
|
||||
export type Writeable<T> = {
|
||||
-readonly [P in keyof T]: T[P];
|
||||
};
|
||||
export type StripCallSignature<T> = {
|
||||
[K in keyof T]: T[K];
|
||||
};
|
||||
export type IsUnion<T> = [T] extends [infer U] ? (U extends any ? (x: U) => any : never) extends (x: infer I) => any ? [T] extends [I] ? false : true : never : never;
|
||||
export type IsAny<T> = 0 extends 1 & T ? true : false;
|
||||
export type AreExact<A, B> = (<T>() => T extends A ? 1 : 2) extends <T>() => T extends B ? 1 : 2 ? true : false;
|
||||
export type AreMutuallyExclusive<A, B> = AreExact<never, A & B>;
|
||||
export type ConstructorReturnType<T extends abstract new (...args: any) => any> = T extends abstract new (...args: any) => infer P ? P : never;
|
||||
type NN<T> = NonNullable<T>;
|
||||
/**
|
||||
* Helper macro for nested NonNullable key accessors.
|
||||
*
|
||||
* The maximum depth is capped at 8. This is intentional to keep the implementation simple. A dynamic & recursive
|
||||
* implementation is possible and would remove this limitation, however the recursive nature would require memory of
|
||||
* exponential complexity (which is impractical, and will choke the TypeScript compiler).
|
||||
*
|
||||
* @example
|
||||
* NonNullablePath< T, 'a', 'b', 'c' >
|
||||
* // expands to...
|
||||
* NonNullable<NonNullable<NonNullable<T>['a']>['b']>['b']>
|
||||
*
|
||||
* @summary Nested NonNullable getters
|
||||
*/
|
||||
export type NonNullablePath<T, K0 extends keyof T = never, K1 extends keyof NN<T[K0]> = never, K2 extends keyof NN<NN<T[K0]>[K1]> = never, K3 extends keyof NN<NN<NN<T[K0]>[K1]>[K2]> = never, K4 extends keyof NN<NN<NN<NN<T[K0]>[K1]>[K2]>[K3]> = never, K5 extends keyof NN<NN<NN<NN<NN<T[K0]>[K1]>[K2]>[K3]>[K4]> = never, K6 extends keyof NN<NN<NN<NN<NN<NN<T[K0]>[K1]>[K2]>[K3]>[K4]>[K5]> = never, K7 extends keyof NN<NN<NN<NN<NN<NN<NN<T[K0]>[K1]>[K2]>[K3]>[K4]>[K5]>[K6]> = never> = [K0] extends [never] ? T : [K1] extends [never] ? NN<T[K0]> : [K2] extends [never] ? NN<NN<T[K0]>[K1]> : [K3] extends [never] ? NN<NN<NN<T[K0]>[K1]>[K2]> : [K4] extends [never] ? NN<NN<NN<NN<T[K0]>[K1]>[K2]>[K3]> : [K5] extends [never] ? NN<NN<NN<NN<NN<T[K0]>[K1]>[K2]>[K3]>[K4]> : [K6] extends [never] ? NN<NN<NN<NN<NN<NN<T[K0]>[K1]>[K2]>[K3]>[K4]>[K5]> : [K7] extends [never] ? NN<NN<NN<NN<NN<NN<NN<T[K0]>[K1]>[K2]>[K3]>[K4]>[K5]>[K6]> : NN<NN<NN<NN<NN<NN<NN<NN<T[K0]>[K1]>[K2]>[K3]>[K4]>[K5]>[K6]>[K7]>;
|
||||
export {};
|
||||
9
node_modules/ag-charts-core/dist/types/src/types/idBranding.d.ts
generated
vendored
Executable file
9
node_modules/ag-charts-core/dist/types/src/types/idBranding.d.ts
generated
vendored
Executable file
@@ -0,0 +1,9 @@
|
||||
declare const elementIDBrand: unique symbol;
|
||||
declare const axisIDBrand: unique symbol;
|
||||
export type ElementID = string & {
|
||||
readonly [elementIDBrand]: true;
|
||||
};
|
||||
export type AxisID = string & {
|
||||
readonly [axisIDBrand]: true;
|
||||
};
|
||||
export {};
|
||||
65
node_modules/ag-charts-core/dist/types/src/types/scales.d.ts
generated
vendored
Executable file
65
node_modules/ag-charts-core/dist/types/src/types/scales.d.ts
generated
vendored
Executable file
@@ -0,0 +1,65 @@
|
||||
import type { AgTimeInterval } from 'ag-charts-types';
|
||||
export type ScaleType = 'number' | 'log' | 'time' | 'unit-time' | 'ordinal-time' | 'category' | 'mercator' | 'color';
|
||||
/**
|
||||
* Metadata about a domain's sort characteristics.
|
||||
* Used to skip expensive sort order detection in scales.
|
||||
*/
|
||||
export interface DomainSortMetadata {
|
||||
/** Sort order: 1 = ascending, -1 = descending, undefined = unsorted/unknown */
|
||||
sortOrder: 1 | -1 | undefined;
|
||||
/** True if all values are unique (no duplicates) */
|
||||
isUnique?: boolean;
|
||||
}
|
||||
/**
|
||||
* A domain array with optional metadata for optimization.
|
||||
* When metadata is present, scales can skip expensive scans.
|
||||
*/
|
||||
export interface DomainWithMetadata<D> {
|
||||
domain: D[];
|
||||
sortMetadata?: DomainSortMetadata;
|
||||
}
|
||||
/**
|
||||
* Extract domain array from a domain with metadata.
|
||||
*/
|
||||
export declare function extractDomain<D>(value: DomainWithMetadata<D>): D[];
|
||||
export interface ScaleTickParams<I> {
|
||||
nice: boolean[];
|
||||
interval: I | undefined;
|
||||
tickCount: number | undefined;
|
||||
minTickCount: number;
|
||||
maxTickCount: number;
|
||||
}
|
||||
export interface NormalizedDomain<D> {
|
||||
domain: D[];
|
||||
animatable: boolean;
|
||||
}
|
||||
export interface ScaleTickResult<D> {
|
||||
ticks: D[];
|
||||
count: number | undefined;
|
||||
firstTickIndex?: number;
|
||||
timeInterval?: AgTimeInterval;
|
||||
}
|
||||
export declare enum ScaleAlignment {
|
||||
Leading = 0,
|
||||
Trailing = 1,
|
||||
Interpolate = 2
|
||||
}
|
||||
export interface Scale<D, R, I = number> {
|
||||
readonly type: ScaleType;
|
||||
readonly defaultTickCount: number;
|
||||
domain: D[];
|
||||
range: R[];
|
||||
getDomainMinMax(): [D, D] | [undefined, undefined];
|
||||
normalizeDomains(...domains: DomainWithMetadata<D>[]): NormalizedDomain<D>;
|
||||
toDomain(value: number): D | undefined;
|
||||
convert(value: D, options?: {
|
||||
clamp?: boolean;
|
||||
alignment?: ScaleAlignment;
|
||||
}): R;
|
||||
invert(value: R, exact?: boolean): D | undefined;
|
||||
ticks(ticks: ScaleTickParams<I>, domain?: D[], visibleRange?: [number, number]): ScaleTickResult<D> | undefined;
|
||||
niceDomain(ticks: ScaleTickParams<I>, domain?: D[]): D[];
|
||||
readonly bandwidth: number | undefined;
|
||||
readonly step: number | undefined;
|
||||
readonly inset: number | undefined;
|
||||
}
|
||||
18
node_modules/ag-charts-core/dist/types/src/types/scene.d.ts
generated
vendored
Executable file
18
node_modules/ag-charts-core/dist/types/src/types/scene.d.ts
generated
vendored
Executable file
@@ -0,0 +1,18 @@
|
||||
export interface Size {
|
||||
width: number;
|
||||
height: number;
|
||||
}
|
||||
export interface Point {
|
||||
x: number;
|
||||
y: number;
|
||||
}
|
||||
export interface SizedPoint extends Point {
|
||||
size: number;
|
||||
focusSize?: number;
|
||||
}
|
||||
export interface Bounds4 {
|
||||
x1: number;
|
||||
y1: number;
|
||||
x2: number;
|
||||
y2: number;
|
||||
}
|
||||
7
node_modules/ag-charts-core/dist/types/src/types/strictMap.d.ts
generated
vendored
Executable file
7
node_modules/ag-charts-core/dist/types/src/types/strictMap.d.ts
generated
vendored
Executable file
@@ -0,0 +1,7 @@
|
||||
/**
|
||||
* A stricter version of `Map` where each key can have its unique value type.
|
||||
*/
|
||||
export interface PerKeyMap<Meta extends object> extends Map<keyof Meta, Meta[keyof Meta]> {
|
||||
set<K extends keyof Meta>(key: K, value: Meta[K]): this;
|
||||
get<K extends keyof Meta>(key: K): Meta[K] | undefined;
|
||||
}
|
||||
53
node_modules/ag-charts-core/dist/types/src/types/text.d.ts
generated
vendored
Executable file
53
node_modules/ag-charts-core/dist/types/src/types/text.d.ts
generated
vendored
Executable file
@@ -0,0 +1,53 @@
|
||||
import type { FontFamily, FontSize, FontStyle, FontWeight, TextSegment } from 'ag-charts-types';
|
||||
import type { Writeable } from './global';
|
||||
import type { Size } from './scene';
|
||||
export declare const EllipsisChar = "\u2026";
|
||||
export declare const LineSplitter: RegExp;
|
||||
export declare const TrimEdgeGuard = "\u200B";
|
||||
export declare const TrimCharsRegex: RegExp;
|
||||
export interface FontOptions {
|
||||
fontSize: FontSize;
|
||||
fontStyle?: FontStyle;
|
||||
fontWeight?: FontWeight;
|
||||
fontFamily?: FontFamily;
|
||||
}
|
||||
export interface TextMetricsBox {
|
||||
width: number;
|
||||
height: number;
|
||||
ascent: number;
|
||||
descent: number;
|
||||
}
|
||||
export interface LineMetricsBox extends TextMetricsBox {
|
||||
text: string;
|
||||
}
|
||||
export interface MultilineTextMetricsBox {
|
||||
width: number;
|
||||
height: number;
|
||||
lineMetrics: LineMetricsBox[];
|
||||
}
|
||||
export interface MeasuredSegment extends Omit<TextSegment, 'text'> {
|
||||
text: string;
|
||||
fontSize: number;
|
||||
textMetrics: TextMetricsBox;
|
||||
}
|
||||
export interface SegmentsLineMetrics extends Size {
|
||||
ascent: number;
|
||||
descent: number;
|
||||
segments: MeasuredSegment[];
|
||||
}
|
||||
export interface MultilineSegmentsMetricsBox {
|
||||
width: number;
|
||||
height: number;
|
||||
lineMetrics: SegmentsLineMetrics[];
|
||||
}
|
||||
export interface LegacyTextMetrics extends Writeable<TextMetrics> {
|
||||
emHeightAscent: number;
|
||||
emHeightDescent: number;
|
||||
}
|
||||
export interface ITextMeasurer {
|
||||
measureText(text: string): TextMetricsBox;
|
||||
measureLines(text: string | string[]): MultilineTextMetricsBox;
|
||||
baselineDistance(textBaseline: CanvasTextBaseline): number;
|
||||
textWidth(text: string, estimate?: boolean): number;
|
||||
lineHeight(): number;
|
||||
}
|
||||
50
node_modules/ag-charts-core/dist/types/src/types/themeConstants.d.ts
generated
vendored
Executable file
50
node_modules/ag-charts-core/dist/types/src/types/themeConstants.d.ts
generated
vendored
Executable file
@@ -0,0 +1,50 @@
|
||||
export declare enum FONT_SIZE {
|
||||
SMALLEST = 8,
|
||||
SMALLER = 10,
|
||||
SMALL = 12,
|
||||
MEDIUM = 13,
|
||||
LARGE = 14,
|
||||
LARGEST = 17
|
||||
}
|
||||
export declare const BASE_FONT_SIZE = FONT_SIZE.SMALL;
|
||||
export declare const FONT_SIZE_RATIO: {
|
||||
SMALLEST: number;
|
||||
SMALLER: number;
|
||||
SMALL: number;
|
||||
MEDIUM: number;
|
||||
LARGE: number;
|
||||
LARGEST: number;
|
||||
};
|
||||
export declare enum CARTESIAN_POSITION {
|
||||
TOP = "top",
|
||||
TOP_RIGHT = "top-right",
|
||||
TOP_LEFT = "top-left",
|
||||
RIGHT = "right",
|
||||
RIGHT_TOP = "right-top",
|
||||
RIGHT_BOTTOM = "right-bottom",
|
||||
BOTTOM = "bottom",
|
||||
BOTTOM_RIGHT = "bottom-right",
|
||||
BOTTOM_LEFT = "bottom-left",
|
||||
LEFT = "left",
|
||||
LEFT_TOP = "left-top",
|
||||
LEFT_BOTTOM = "left-bottom"
|
||||
}
|
||||
export declare enum CARTESIAN_AXIS_TYPE {
|
||||
CATEGORY = "category",
|
||||
GROUPED_CATEGORY = "grouped-category",
|
||||
ORDINAL_TIME = "ordinal-time",
|
||||
UNIT_TIME = "unit-time",
|
||||
TIME = "time",
|
||||
NUMBER = "number",
|
||||
LOG = "log"
|
||||
}
|
||||
export declare enum POLAR_AXIS_TYPE {
|
||||
ANGLE_CATEGORY = "angle-category",
|
||||
ANGLE_NUMBER = "angle-number",
|
||||
RADIUS_CATEGORY = "radius-category",
|
||||
RADIUS_NUMBER = "radius-number"
|
||||
}
|
||||
export declare enum POLAR_AXIS_SHAPE {
|
||||
CIRCLE = "circle",
|
||||
POLYGON = "polygon"
|
||||
}
|
||||
33
node_modules/ag-charts-core/dist/types/src/types/themeSymbols.d.ts
generated
vendored
Executable file
33
node_modules/ag-charts-core/dist/types/src/types/themeSymbols.d.ts
generated
vendored
Executable file
@@ -0,0 +1,33 @@
|
||||
export declare const IS_DARK_THEME: boolean;
|
||||
export declare const DEFAULT_SHADOW_COLOUR: string;
|
||||
export declare const DEFAULT_CAPTION_LAYOUT_STYLE: string;
|
||||
export declare const DEFAULT_CAPTION_ALIGNMENT: string;
|
||||
export declare const PALETTE_UP_STROKE: string;
|
||||
export declare const PALETTE_DOWN_STROKE: string;
|
||||
export declare const PALETTE_UP_FILL: string;
|
||||
export declare const PALETTE_DOWN_FILL: string;
|
||||
export declare const PALETTE_NEUTRAL_STROKE: string;
|
||||
export declare const PALETTE_NEUTRAL_FILL: string;
|
||||
export declare const PALETTE_ALT_UP_STROKE: string;
|
||||
export declare const PALETTE_ALT_DOWN_STROKE: string;
|
||||
export declare const PALETTE_ALT_UP_FILL: string;
|
||||
export declare const PALETTE_ALT_DOWN_FILL: string;
|
||||
export declare const PALETTE_ALT_NEUTRAL_FILL: string;
|
||||
export declare const PALETTE_ALT_NEUTRAL_STROKE: string;
|
||||
export declare const DEFAULT_POLAR_SERIES_STROKE: string;
|
||||
export declare const DEFAULT_SPARKLINE_CROSSHAIR_STROKE: string;
|
||||
export declare const DEFAULT_FINANCIAL_CHARTS_ANNOTATION_COLOR: string;
|
||||
export declare const DEFAULT_FIBONACCI_STROKES: string;
|
||||
export declare const DEFAULT_TEXT_ANNOTATION_COLOR: string;
|
||||
export declare const DEFAULT_FINANCIAL_CHARTS_ANNOTATION_BACKGROUND_FILL: string;
|
||||
export declare const DEFAULT_ANNOTATION_HANDLE_FILL: string;
|
||||
export declare const DEFAULT_ANNOTATION_STATISTICS_FILL: string;
|
||||
export declare const DEFAULT_ANNOTATION_STATISTICS_STROKE: string;
|
||||
export declare const DEFAULT_ANNOTATION_STATISTICS_COLOR: string;
|
||||
export declare const DEFAULT_ANNOTATION_STATISTICS_DIVIDER_STROKE: string;
|
||||
export declare const DEFAULT_ANNOTATION_STATISTICS_DOWN_FILL: string;
|
||||
export declare const DEFAULT_ANNOTATION_STATISTICS_DOWN_STROKE: string;
|
||||
export declare const DEFAULT_TEXTBOX_FILL: string;
|
||||
export declare const DEFAULT_TEXTBOX_STROKE: string;
|
||||
export declare const DEFAULT_TEXTBOX_COLOR: string;
|
||||
export declare const DEFAULT_TOOLBAR_POSITION: string;
|
||||
14
node_modules/ag-charts-core/dist/types/src/types/updateType.d.ts
generated
vendored
Executable file
14
node_modules/ag-charts-core/dist/types/src/types/updateType.d.ts
generated
vendored
Executable file
@@ -0,0 +1,14 @@
|
||||
/** Types of chart-update, in pipeline execution order. */
|
||||
export declare enum ChartUpdateType {
|
||||
FULL = 0,
|
||||
UPDATE_DATA = 1,
|
||||
PROCESS_DATA = 2,
|
||||
PROCESS_DOMAIN = 3,
|
||||
PROCESS_RANGE = 4,
|
||||
PERFORM_LAYOUT = 5,
|
||||
PRE_SERIES_UPDATE = 6,
|
||||
SERIES_UPDATE = 7,
|
||||
PRE_SCENE_RENDER = 8,
|
||||
SCENE_RENDER = 9,
|
||||
NONE = 10
|
||||
}
|
||||
39
node_modules/ag-charts-core/dist/types/src/types/zIndexMap.d.ts
generated
vendored
Executable file
39
node_modules/ag-charts-core/dist/types/src/types/zIndexMap.d.ts
generated
vendored
Executable file
@@ -0,0 +1,39 @@
|
||||
/**
|
||||
* Constants to declare the expected nominal zIndex for all types of layer in chart rendering.
|
||||
*/
|
||||
export declare enum ZIndexMap {
|
||||
CHART_BACKGROUND = 0,
|
||||
AXIS_BAND_HIGHLIGHT = 1,
|
||||
AXIS_GRID = 2,
|
||||
AXIS = 3,
|
||||
SERIES_AREA_CONTAINER = 4,
|
||||
ZOOM_SELECTION = 5,
|
||||
SERIES_CROSSLINE_RANGE = 6,
|
||||
SERIES_LAYER = 7,
|
||||
AXIS_FOREGROUND = 8,
|
||||
SERIES_CROSSHAIR = 9,
|
||||
SERIES_CROSSLINE_LINE = 10,
|
||||
SERIES_ANNOTATION = 11,
|
||||
CHART_ANNOTATION = 12,
|
||||
CHART_ANNOTATION_FOCUSED = 13,
|
||||
STATUS_BAR = 14,
|
||||
SERIES_LABEL = 15,
|
||||
LEGEND = 16,
|
||||
NAVIGATOR = 17,
|
||||
FOREGROUND = 18
|
||||
}
|
||||
export declare enum SeriesZIndexMap {
|
||||
BACKGROUND = 0,
|
||||
ANY_CONTENT = 1
|
||||
}
|
||||
export declare enum SeriesContentZIndexMap {
|
||||
FOREGROUND = 0,
|
||||
HIGHLIGHT = 1,
|
||||
LABEL = 2
|
||||
}
|
||||
export declare enum PolarZIndexMap {
|
||||
BACKGROUND = 0,
|
||||
FOREGROUND = 1,
|
||||
HIGHLIGHT = 2,
|
||||
LABEL = 3
|
||||
}
|
||||
137
node_modules/ag-charts-core/dist/types/src/utils/aggregation.d.ts
generated
vendored
Executable file
137
node_modules/ag-charts-core/dist/types/src/utils/aggregation.d.ts
generated
vendored
Executable file
@@ -0,0 +1,137 @@
|
||||
import type { DomainWithMetadata, ScaleType } from '../types/scales';
|
||||
export declare const AGGREGATION_INDEX_X_MIN = 0;
|
||||
export declare const AGGREGATION_INDEX_X_MAX = 1;
|
||||
export declare const AGGREGATION_INDEX_Y_MIN = 2;
|
||||
export declare const AGGREGATION_INDEX_Y_MAX = 3;
|
||||
export declare const AGGREGATION_SPAN = 4;
|
||||
export declare const AGGREGATION_THRESHOLD = 1000;
|
||||
export declare const AGGREGATION_MAX_POINTS = 10;
|
||||
export declare const AGGREGATION_MIN_RANGE = 64;
|
||||
export declare const AGGREGATION_INDEX_UNSET = 4294967295;
|
||||
export declare function aggregationRangeFittingPoints(xValues: any[], d0: number, d1: number, opts?: {
|
||||
smallestKeyInterval?: number;
|
||||
xNeedsValueOf?: boolean;
|
||||
}): number;
|
||||
export declare function aggregationDomain(scale: ScaleType, domainInput: DomainWithMetadata<any>): [number, number];
|
||||
export declare function aggregationXRatioForDatumIndex(datumIndex: any, domainCount: number): number;
|
||||
export declare function aggregationXRatioForXValue(xValue: any, d0: number, d1: number, xNeedsValueOf: boolean): number;
|
||||
export declare function aggregationIndexForXRatio(xRatio: number, maxRange: number): number;
|
||||
export declare function aggregationBucketForDatum(xValues: any[], d0: number, d1: number, maxRange: number, datumIndex: number, { xNeedsValueOf, xValuesLength }?: {
|
||||
xNeedsValueOf?: boolean;
|
||||
xValuesLength?: number;
|
||||
}): number;
|
||||
export declare function aggregationDatumMatchesIndex(indexData: Uint32Array, aggIndex: number, datumIndex: number, offsets: number[]): boolean;
|
||||
export declare function createAggregationIndices(xValues: any[], yMaxValues: any[], yMinValues: any[], d0: number, d1: number, maxRange: number, { positive, split, xNeedsValueOf, yNeedsValueOf, reuseIndexData, reuseValueData, reuseNegativeIndexData, reuseNegativeValueData, }?: {
|
||||
positive?: boolean;
|
||||
split?: boolean;
|
||||
xNeedsValueOf?: boolean;
|
||||
yNeedsValueOf?: boolean;
|
||||
reuseIndexData?: Uint32Array;
|
||||
reuseValueData?: Float64Array;
|
||||
reuseNegativeIndexData?: Uint32Array;
|
||||
reuseNegativeValueData?: Float64Array;
|
||||
}): {
|
||||
indexData: Uint32Array;
|
||||
valueData: Float64Array;
|
||||
negativeIndexData?: Uint32Array;
|
||||
negativeValueData?: Float64Array;
|
||||
};
|
||||
export declare function compactAggregationIndices(indexData: Uint32Array, valueData: Float64Array, maxRange: number, { inPlace, midpointData, reuseIndexData, reuseValueData, }?: {
|
||||
inPlace?: boolean;
|
||||
midpointData?: Uint32Array;
|
||||
reuseIndexData?: Uint32Array;
|
||||
reuseValueData?: Float64Array;
|
||||
}): {
|
||||
maxRange: number;
|
||||
indexData: Uint32Array;
|
||||
valueData: Float64Array;
|
||||
midpointData: Uint32Array;
|
||||
};
|
||||
export interface AggregationLevelState {
|
||||
maxRange: number;
|
||||
indexData: Uint32Array;
|
||||
valueData: Float64Array;
|
||||
midpointData?: Uint32Array;
|
||||
}
|
||||
/**
|
||||
* Computes midpoint indices from aggregation index data.
|
||||
* For each bucket, calculates the midpoint between min and max X indices.
|
||||
*
|
||||
* This generic helper consolidates the `getMidpoints()` functions from
|
||||
* rangeBarAggregation and ohlcAggregation, and `getIndices()` from barAggregation.
|
||||
*
|
||||
* @param maxRange - Number of aggregation buckets
|
||||
* @param indexData - Aggregation index data (TypedArray)
|
||||
* @param reuseMidpointData - Optional pre-allocated array to reuse (must be correct size)
|
||||
* @param xMinOffset - Offset for the X min index within each bucket
|
||||
* @param xMaxOffset - Offset for the X max index within each bucket
|
||||
* @param invalidSentinel - Sentinel value indicating invalid/empty buckets (-1 or AGGREGATION_INDEX_UNSET)
|
||||
* @returns Array of midpoint indices representing each bucket
|
||||
*/
|
||||
export declare function getMidpointsForIndices(maxRange: number, indexData: Uint32Array, reuseMidpointData?: Uint32Array, xMinOffset?: number, xMaxOffset?: number, invalidSentinel?: number): Uint32Array;
|
||||
export declare function collectAggregationLevels<T>(state: AggregationLevelState, { collectLevel, shouldContinue, minRange, compactInPlace, }: {
|
||||
collectLevel: (state: AggregationLevelState) => T;
|
||||
shouldContinue: (level: T, state: AggregationLevelState) => boolean;
|
||||
minRange?: number;
|
||||
compactInPlace?: boolean;
|
||||
}): T[];
|
||||
/**
|
||||
* Filter interface for extremes-based aggregation (OHLC, RangeBar).
|
||||
* Tracks indices that represent extrema values within each aggregation bucket.
|
||||
*/
|
||||
export interface ExtremesAggregationFilter {
|
||||
indexData: Uint32Array;
|
||||
valueData: Float64Array;
|
||||
maxRange: number;
|
||||
midpointIndices: Uint32Array;
|
||||
}
|
||||
/**
|
||||
* Result type for partial extremes aggregation with deferred computation.
|
||||
*/
|
||||
export interface ExtremesPartialAggregationResult {
|
||||
/** Levels computed immediately (includes the target level) */
|
||||
immediate: ExtremesAggregationFilter[];
|
||||
/** Function to compute remaining coarser levels, or undefined if all levels computed */
|
||||
computeRemaining?: () => ExtremesAggregationFilter[];
|
||||
}
|
||||
/**
|
||||
* Computes multi-level aggregation filters for extremes-based chart data (OHLC, RangeBar).
|
||||
*
|
||||
* Creates progressively coarser aggregation levels for efficient rendering
|
||||
* of large datasets. Tracks extrema values (min/max for both X and Y) as indices
|
||||
* within each aggregation bucket.
|
||||
*
|
||||
* @param domain - Numeric domain bounds [min, max] for X values
|
||||
* @param xValues - X coordinate values (typically time/date)
|
||||
* @param highValues - High/max Y values for each data point
|
||||
* @param lowValues - Low/min Y values for each data point
|
||||
* @param options - Configuration options
|
||||
* @returns Array of aggregation filters from coarse to fine resolution, or undefined if below threshold
|
||||
*/
|
||||
export declare function computeExtremesAggregation(domain: [number, number], xValues: any[], highValues: any[], lowValues: any[], options: {
|
||||
smallestKeyInterval: number | undefined;
|
||||
xNeedsValueOf: boolean;
|
||||
yNeedsValueOf: boolean;
|
||||
existingFilters?: ExtremesAggregationFilter[];
|
||||
}): ExtremesAggregationFilter[] | undefined;
|
||||
/**
|
||||
* Computes extremes aggregation with deferred full recomputation.
|
||||
*
|
||||
* For real-time data updates, this computes only the single aggregation level
|
||||
* needed for the current zoom, deferring a full recomputation of all levels
|
||||
* to idle time.
|
||||
*
|
||||
* @param domain - Numeric domain bounds [min, max] for X values
|
||||
* @param xValues - X coordinate values
|
||||
* @param highValues - High/max Y values
|
||||
* @param lowValues - Low/min Y values
|
||||
* @param options - Configuration options including targetRange
|
||||
* @returns Partial result with the immediate level and a function to compute all levels
|
||||
*/
|
||||
export declare function computeExtremesAggregationPartial(domain: [number, number], xValues: any[], highValues: any[], lowValues: any[], options: {
|
||||
smallestKeyInterval: number | undefined;
|
||||
targetRange: number;
|
||||
xNeedsValueOf: boolean;
|
||||
yNeedsValueOf: boolean;
|
||||
existingFilters?: ExtremesAggregationFilter[];
|
||||
}): ExtremesPartialAggregationResult | undefined;
|
||||
13
node_modules/ag-charts-core/dist/types/src/utils/async.d.ts
generated
vendored
Executable file
13
node_modules/ag-charts-core/dist/types/src/utils/async.d.ts
generated
vendored
Executable file
@@ -0,0 +1,13 @@
|
||||
/**
|
||||
* Primitive to allow coordination between async processes.
|
||||
*/
|
||||
export declare class AsyncAwaitQueue {
|
||||
private readonly queue;
|
||||
/** Await another async process to call notify(). */
|
||||
waitForCompletion(timeout?: number): Promise<boolean>;
|
||||
/** Trigger any await()ing async processes to continue. */
|
||||
notify(): void;
|
||||
}
|
||||
export declare function pause(delayMilliseconds?: number): Promise<any>;
|
||||
/** Wraps a promise with a timeout. Rejects with an error if the timeout expires before resolution. */
|
||||
export declare function withTimeout<T>(promise: Promise<T>, timeoutMs: number, errorMessage?: string): Promise<T>;
|
||||
1
node_modules/ag-charts-core/dist/types/src/utils/canvas.d.ts
generated
vendored
Executable file
1
node_modules/ag-charts-core/dist/types/src/utils/canvas.d.ts
generated
vendored
Executable file
@@ -0,0 +1 @@
|
||||
export declare function createCanvasContext(width?: number, height?: number): CanvasRenderingContext2D;
|
||||
70
node_modules/ag-charts-core/dist/types/src/utils/configuredCanvasMixin.d.ts
generated
vendored
Executable file
70
node_modules/ag-charts-core/dist/types/src/utils/configuredCanvasMixin.d.ts
generated
vendored
Executable file
@@ -0,0 +1,70 @@
|
||||
/** Type representing a constructor function. */
|
||||
export type Constructor<T> = new (...args: any[]) => T;
|
||||
/**
|
||||
* Minimal interface for what a Canvas-like class must provide.
|
||||
* This allows the mixin to work with any canvas implementation (e.g., skia-canvas).
|
||||
* Uses loose typing to accommodate different canvas implementations.
|
||||
*/
|
||||
export interface CanvasLike {
|
||||
width: number;
|
||||
height: number;
|
||||
gpu: boolean;
|
||||
getContext(type: '2d'): unknown;
|
||||
toBuffer(format: string, options?: {
|
||||
quality?: number;
|
||||
msaa?: boolean;
|
||||
}): Promise<Uint8Array>;
|
||||
toDataURLSync?(mimeType: string): string;
|
||||
}
|
||||
/** Default canvas width for test/SSR rendering. */
|
||||
export declare const CANVAS_WIDTH = 800;
|
||||
/** Default canvas height for test/SSR rendering. */
|
||||
export declare const CANVAS_HEIGHT = 600;
|
||||
/** Default buffer options for consistent rendering output. */
|
||||
export declare const CANVAS_TO_BUFFER_DEFAULTS: {
|
||||
quality: number;
|
||||
};
|
||||
/**
|
||||
* Mixin that configures a Canvas class for consistent SSR/test rendering.
|
||||
* Disables GPU acceleration and MSAA for deterministic output.
|
||||
*
|
||||
* Usage:
|
||||
* ```typescript
|
||||
* import { Canvas } from 'skia-canvas';
|
||||
* import { ConfiguredCanvasMixin } from 'ag-charts-core';
|
||||
*
|
||||
* export const ConfiguredCanvas = ConfiguredCanvasMixin(Canvas);
|
||||
* ```
|
||||
*/
|
||||
export declare function ConfiguredCanvasMixin<T extends Constructor<CanvasLike>>(Base: T): {
|
||||
new (...args: any[]): {
|
||||
toBuffer(format: string, options?: {
|
||||
quality?: number;
|
||||
msaa?: boolean;
|
||||
}): Promise<Uint8Array>;
|
||||
transferToImageBitmap(): CanvasLike;
|
||||
width: number;
|
||||
height: number;
|
||||
gpu: boolean;
|
||||
getContext(type: "2d"): unknown;
|
||||
toDataURLSync?(mimeType: string): string;
|
||||
};
|
||||
} & T;
|
||||
/**
|
||||
* Apply skia-canvas patches for consistent rendering.
|
||||
* Call once at module initialization in consuming packages.
|
||||
*
|
||||
* Patches:
|
||||
* - createConicGradient: Fixes angle offset (https://github.com/samizdatco/skia-canvas/issues/241)
|
||||
* - fillText: Uses path-based text rendering for consistent output
|
||||
*
|
||||
* Usage:
|
||||
* ```typescript
|
||||
* import * as SkiaCanvas from 'skia-canvas';
|
||||
* import { DOMMatrix } from 'skia-canvas';
|
||||
* import { applySkiaPatches } from 'ag-charts-core';
|
||||
*
|
||||
* applySkiaPatches(SkiaCanvas.CanvasRenderingContext2D, DOMMatrix);
|
||||
* ```
|
||||
*/
|
||||
export declare function applySkiaPatches(CanvasRenderingContext2D: any, DOMMatrix: any): void;
|
||||
47
node_modules/ag-charts-core/dist/types/src/utils/data/arrays.d.ts
generated
vendored
Executable file
47
node_modules/ag-charts-core/dist/types/src/utils/data/arrays.d.ts
generated
vendored
Executable file
@@ -0,0 +1,47 @@
|
||||
/**
|
||||
* Converts a value to an array. If the value is already an array, it is returned as-is.
|
||||
* @param value - The value to convert.
|
||||
* @returns The resulting array.
|
||||
*/
|
||||
export declare function toArray<T>(value: T | T[] | undefined): T[];
|
||||
/**
|
||||
* Removes duplicate values from an array.
|
||||
* @param array - The array to process.
|
||||
* @returns A new array with unique values.
|
||||
*/
|
||||
export declare function unique<T>(array: T[]): T[];
|
||||
/**
|
||||
* Groups items in an array by a key generated from the `iteratee` function.
|
||||
* @param array - The array to group.
|
||||
* @param iteratee - A function that generates the key for each item.
|
||||
* @returns An object where the keys are the group keys and the values are arrays of grouped items.
|
||||
*/
|
||||
export declare function groupBy<T, R extends string | number | symbol>(array: T[], iteratee: (item: T) => R): { [K in R]?: T[] | undefined; };
|
||||
/**
|
||||
* Compares two arrays for deep equality, including nested arrays.
|
||||
* @param a - The first array.
|
||||
* @param b - The second array.
|
||||
* @returns `true` if the arrays are equal, otherwise `false`.
|
||||
*/
|
||||
export declare function arraysEqual(a: readonly any[], b: readonly any[]): boolean;
|
||||
/**
|
||||
* Creates a circular slice of an array.
|
||||
* @param data - The source array.
|
||||
* @param size - The size of the slice.
|
||||
* @param offset - The starting index for the slice (default is 0).
|
||||
* @returns A circular slice of the array.
|
||||
*/
|
||||
export declare function circularSliceArray<T>(data: T[], size: number, offset?: number): T[];
|
||||
/**
|
||||
* Sorts a base array according to the order defined in a reference array.
|
||||
* @param baseArray - The array to sort.
|
||||
* @param orderArray - The array defining the desired order.
|
||||
* @returns The sorted array.
|
||||
*/
|
||||
export declare function sortBasedOnArray<T>(baseArray: T[], orderArray: T[]): T[];
|
||||
export declare function dropFirstWhile<T>(array: T[], cond: (value: T) => boolean): void;
|
||||
export declare function dropLastWhile<T>(array: T[], cond: (value: T) => boolean): void;
|
||||
/**
|
||||
* Creates an even distribution of numbers between `min` and `max`.
|
||||
*/
|
||||
export declare function distribute(min: number, max: number, maxCount: number): number[];
|
||||
40
node_modules/ag-charts-core/dist/types/src/utils/data/binarySearch.d.ts
generated
vendored
Executable file
40
node_modules/ag-charts-core/dist/types/src/utils/data/binarySearch.d.ts
generated
vendored
Executable file
@@ -0,0 +1,40 @@
|
||||
/**
|
||||
* Finds the maximum value that matches a condition within a specified range.
|
||||
*
|
||||
* @template T
|
||||
* @param {number} min - The minimum number in the range.
|
||||
* @param {number} max - The maximum number in the range.
|
||||
* @param {function(number): boolean} iteratee - A function that takes a number and returns a value of type T or undefined.
|
||||
* @returns {number | undefined} - The maximum value that matches the condition, or undefined if no match is found.
|
||||
*/
|
||||
export declare function findMaxIndex(min: number, max: number, iteratee: (value: number) => boolean): number | undefined;
|
||||
/**
|
||||
* Finds the minimum value that matches a condition within a specified range.
|
||||
*
|
||||
* @template T
|
||||
* @param {number} min - The minimum number in the range.
|
||||
* @param {number} max - The maximum number in the range.
|
||||
* @param {function(number): boolean} iteratee - A function that takes a number and returns a value of type T or undefined.
|
||||
* @returns {number | undefined} - The minimum value that matches the condition, or undefined if no match is found.
|
||||
*/
|
||||
export declare function findMinIndex(min: number, max: number, iteratee: (value: number) => boolean): number | undefined;
|
||||
/**
|
||||
* Finds the maximum value that matches a condition within a specified range.
|
||||
*
|
||||
* @template T
|
||||
* @param {number} min - The minimum number in the range.
|
||||
* @param {number} max - The maximum number in the range.
|
||||
* @param {function(number): (T | undefined)} iteratee - A function that takes a number and returns a value of type T or undefined.
|
||||
* @returns {T | undefined} - The maximum value that matches the condition, or undefined if no match is found.
|
||||
*/
|
||||
export declare function findMaxValue<T>(min: number, max: number, iteratee: (value: number) => T | undefined): T | undefined;
|
||||
/**
|
||||
* Finds the minimum value that matches a condition within a specified range.
|
||||
*
|
||||
* @template T
|
||||
* @param {number} min - The minimum number in the range.
|
||||
* @param {number} max - The maximum number in the range.
|
||||
* @param {function(number): (T | undefined)} iteratee - A function that takes a number and returns a value of type T or undefined.
|
||||
* @returns {T | undefined} - The minimum value that matches the condition, or undefined if no match is found.
|
||||
*/
|
||||
export declare function findMinValue<T>(min: number, max: number, iteratee: (value: number) => T | undefined): T | undefined;
|
||||
17
node_modules/ag-charts-core/dist/types/src/utils/data/diff.d.ts
generated
vendored
Executable file
17
node_modules/ag-charts-core/dist/types/src/utils/data/diff.d.ts
generated
vendored
Executable file
@@ -0,0 +1,17 @@
|
||||
/**
|
||||
* Compares two arrays and returns the differences between them, identifying added and removed elements.
|
||||
*
|
||||
* @template T - The type of elements in the arrays.
|
||||
* @param {T[]} previous - The original array before changes.
|
||||
* @param {T[]} current - The modified array after changes.
|
||||
* @returns {{ changed: boolean, added: Set<T>, removed: Set<T> }}
|
||||
* - An object containing:
|
||||
* - `changed`: A boolean indicating if there are any changes.
|
||||
* - `added`: A set of elements that were added to the current array.
|
||||
* - `removed`: A set of elements that were removed from the previous array.
|
||||
*/
|
||||
export declare function diffArrays<T>(previous: T[], current: T[]): {
|
||||
changed: boolean;
|
||||
added: Set<T>;
|
||||
removed: Set<T>;
|
||||
};
|
||||
10
node_modules/ag-charts-core/dist/types/src/utils/data/extent.d.ts
generated
vendored
Executable file
10
node_modules/ag-charts-core/dist/types/src/utils/data/extent.d.ts
generated
vendored
Executable file
@@ -0,0 +1,10 @@
|
||||
import type { DomainWithMetadata } from '../../types/scales';
|
||||
export declare function extent(values: Array<unknown>, sortOrder?: 1 | -1): [number, number] | null;
|
||||
export declare function normalisedExtentWithMetadata<T>(d: T[], min?: T, max?: T, preferredMin?: T, preferredMax?: T, toValue?: (x: number) => T, sortOrder?: 1 | -1): {
|
||||
extent: T[];
|
||||
clipped: boolean;
|
||||
};
|
||||
export declare function normalisedTimeExtentWithMetadata(input: DomainWithMetadata<Date>, min?: Date | number, max?: Date | number, preferredMin?: Date | number, preferredMax?: Date | number): {
|
||||
extent: Date[];
|
||||
clipped: boolean;
|
||||
};
|
||||
32
node_modules/ag-charts-core/dist/types/src/utils/data/iterators.d.ts
generated
vendored
Executable file
32
node_modules/ag-charts-core/dist/types/src/utils/data/iterators.d.ts
generated
vendored
Executable file
@@ -0,0 +1,32 @@
|
||||
/**
|
||||
* Yields items from multiple iterables in sequence. If a value is not iterable,
|
||||
* it is yielded directly.
|
||||
*
|
||||
* @param items - A list of iterable objects or values.
|
||||
* @returns A generator yielding all items from the input iterables, or the values themselves if not iterable.
|
||||
*/
|
||||
export declare function iterate<T extends any[]>(...items: T): Generator<T[number] extends Iterable<infer U> ? U : T[number], void, undefined>;
|
||||
/**
|
||||
* Converts a value into an iterable. If the value is not already iterable, it wraps it in an array.
|
||||
* @param value - The value to convert.
|
||||
* @returns An iterable representing the value.
|
||||
*/
|
||||
export declare function toIterable<T>(value: T | Iterable<T>): Iterable<T>;
|
||||
/**
|
||||
* Returns the first value from an iterable sequence.
|
||||
* @param iterable source of values
|
||||
* @returns The first value, or throws an error is there is no first value.
|
||||
*/
|
||||
export declare function first<T>(iterable: Iterable<T>): T | never;
|
||||
/**
|
||||
* Efficient key/value iterator. Note that the returned tuple is always the same array, only
|
||||
* elements change from one iteration to the next, so should only be used in destructing for
|
||||
* statements.
|
||||
*
|
||||
* NOTE: For performance sensitive code, prefer using `Object.keys()` directly, or consider
|
||||
* using a `Map` instead.
|
||||
*
|
||||
* @param obj to iterate over
|
||||
* @returns An iterator for all key/value tuples of obj
|
||||
*/
|
||||
export declare function entries<T extends object>(obj: T): Iterable<[keyof T, T[keyof T]]>;
|
||||
80
node_modules/ag-charts-core/dist/types/src/utils/data/json.d.ts
generated
vendored
Executable file
80
node_modules/ag-charts-core/dist/types/src/utils/data/json.d.ts
generated
vendored
Executable file
@@ -0,0 +1,80 @@
|
||||
import type { DeepPartial } from '../../types/global';
|
||||
type StringSet = {
|
||||
has(value: string): boolean;
|
||||
};
|
||||
export type CloneOptions = {
|
||||
shallow?: StringSet;
|
||||
assign?: StringSet;
|
||||
seen?: unknown[];
|
||||
};
|
||||
/**
|
||||
* Performs a recursive JSON-diff between a source and target JSON structure.
|
||||
*
|
||||
* On a per-property basis, takes the target property value where:
|
||||
* - types are different.
|
||||
* - type is primitive.
|
||||
* - type is array and length or content have changed.
|
||||
*
|
||||
* @param source starting point for diff
|
||||
* @param target target for diff vs. source
|
||||
* @param shallow object keys to only shallow compare during diff
|
||||
* @returns `null` if no differences, or an object with the subset of properties that have changed.
|
||||
*/
|
||||
export declare function jsonDiff<T>(source: T, target: T, shallow?: Set<keyof T>): Partial<T> | null;
|
||||
/**
|
||||
* Compares all properties of source against target's properties of the same name.
|
||||
*
|
||||
* @param source object to read properties from
|
||||
* @param target object to compare property values with
|
||||
*
|
||||
* @returns true if all properties in source have identical values in target
|
||||
*/
|
||||
export declare function jsonPropertyCompare<T>(source: Partial<T>, target: T): boolean;
|
||||
/**
|
||||
* Recursively clones of primitives and objects.
|
||||
*
|
||||
* @param source object | array
|
||||
* @param shallow
|
||||
*
|
||||
* @return deep clone of source
|
||||
*/
|
||||
export declare function deepClone<T>(source: T, opts?: CloneOptions): T;
|
||||
/**
|
||||
* Clones of primitives and objects.
|
||||
*
|
||||
* @param source any value
|
||||
*
|
||||
* @return shallow clone of source
|
||||
*/
|
||||
export declare function shallowClone<T>(source: T): T;
|
||||
/**
|
||||
* Walk the given JSON object graphs, invoking the visit() callback for every object encountered.
|
||||
* Arrays are descended into without a callback, however their elements will have the visit()
|
||||
* callback invoked if they are objects.
|
||||
*
|
||||
* @param json to traverse
|
||||
* @param visit callback for each non-primitive and non-array object found
|
||||
* @param skip property names to skip when walking
|
||||
* @param parallelJson to traverse in parallel
|
||||
* @param ctx
|
||||
* @param acc initial accumulator value
|
||||
*/
|
||||
export declare function jsonWalk<T, C, R>(json: T, visit: (node: T, parallelNode?: T, ctx?: C, acc?: R) => R, skip?: Set<string>, parallelJson?: T, ctx?: C, acc?: R): R;
|
||||
/**
|
||||
* Recursively apply a JSON object into a class-hierarchy, optionally instantiating certain classes
|
||||
* by property name.
|
||||
*
|
||||
* @param target to apply source JSON properties into
|
||||
* @param source to be applied
|
||||
* @param params
|
||||
* @param params.path path for logging/error purposes, to aid with pinpointing problems
|
||||
* @param params.matcherPath path for pattern matching, to lookup allowedTypes override.
|
||||
* @param params.skip property names to skip from the source
|
||||
* @param params.constructedArrays map stores arrays which items should be initialised using a class constructor
|
||||
*/
|
||||
export declare function jsonApply<Target extends object, Source extends DeepPartial<Target>>(target: Target, source?: Source, params?: {
|
||||
path?: string;
|
||||
matcherPath?: string;
|
||||
skip?: string[];
|
||||
}): Target;
|
||||
export {};
|
||||
7
node_modules/ag-charts-core/dist/types/src/utils/data/linkedList.d.ts
generated
vendored
Executable file
7
node_modules/ag-charts-core/dist/types/src/utils/data/linkedList.d.ts
generated
vendored
Executable file
@@ -0,0 +1,7 @@
|
||||
type LinkedListItem<T> = {
|
||||
value: T;
|
||||
next: LinkedListItem<T> | null;
|
||||
};
|
||||
export type LinkedList<T> = LinkedListItem<T> | null;
|
||||
export declare function insertListItemsSorted<T>(list: LinkedList<T>, items: T[], cmp: (a: T, b: T) => number): LinkedList<T>;
|
||||
export {};
|
||||
20
node_modules/ag-charts-core/dist/types/src/utils/data/nearest.d.ts
generated
vendored
Executable file
20
node_modules/ag-charts-core/dist/types/src/utils/data/nearest.d.ts
generated
vendored
Executable file
@@ -0,0 +1,20 @@
|
||||
export type NearestResult<T> = {
|
||||
nearest: T | undefined;
|
||||
distanceSquared: number;
|
||||
};
|
||||
export interface DistantObject {
|
||||
distanceSquared(x: number, y: number): number;
|
||||
}
|
||||
type NearestCalculator<TNearest> = {
|
||||
nearestSquared(x: number, y: number, maxDistance: number): NearestResult<TNearest>;
|
||||
};
|
||||
type DistantContainer<TNearest> = {
|
||||
children: Iterable<NearestCalculator<TNearest>>;
|
||||
transformPoint?: (x: number, y: number) => {
|
||||
x: number;
|
||||
y: number;
|
||||
};
|
||||
};
|
||||
export declare function nearestSquared<TObject extends DistantObject>(x: number, y: number, objects: Iterable<TObject>, maxDistanceSquared?: number): NearestResult<TObject>;
|
||||
export declare function nearestSquaredInContainer<TNearest>(x: number, y: number, container: DistantContainer<TNearest>, maxDistanceSquared?: number): NearestResult<TNearest>;
|
||||
export {};
|
||||
5
node_modules/ag-charts-core/dist/types/src/utils/data/numberArray.d.ts
generated
vendored
Executable file
5
node_modules/ag-charts-core/dist/types/src/utils/data/numberArray.d.ts
generated
vendored
Executable file
@@ -0,0 +1,5 @@
|
||||
export declare function clampArray(value: number, array: readonly number[]): number;
|
||||
export declare function findMinMax(array: readonly number[]): number[];
|
||||
export declare function findRangeExtent(array: number[]): number;
|
||||
export declare function nextPowerOf2(value: number): number;
|
||||
export declare function previousPowerOf2(value: number): number;
|
||||
13
node_modules/ag-charts-core/dist/types/src/utils/data/numbers.d.ts
generated
vendored
Executable file
13
node_modules/ag-charts-core/dist/types/src/utils/data/numbers.d.ts
generated
vendored
Executable file
@@ -0,0 +1,13 @@
|
||||
export declare function clamp(min: number, value: number, max: number): number;
|
||||
export declare function inRange(value: number, range: [number, number], epsilon?: number): boolean;
|
||||
export declare function isNumberEqual(a: number, b: number, epsilon?: number): boolean;
|
||||
export declare function isNegative(value: number): boolean;
|
||||
export declare function isInteger(value: number): boolean;
|
||||
export declare function roundTo(value: number, decimals?: number): number;
|
||||
export declare function ceilTo(value: number, decimals?: number): number;
|
||||
/**
|
||||
* Returns the mathematically correct n modulus of m. For context, the JS % operator is remainder
|
||||
* NOT modulus, which is why this is needed.
|
||||
*/
|
||||
export declare function modulus(n: number, m: number): number;
|
||||
export declare function countFractionDigits(value: number): number;
|
||||
39
node_modules/ag-charts-core/dist/types/src/utils/data/object.d.ts
generated
vendored
Executable file
39
node_modules/ag-charts-core/dist/types/src/utils/data/object.d.ts
generated
vendored
Executable file
@@ -0,0 +1,39 @@
|
||||
import type { Intersection, PlainObject } from '../../types/global';
|
||||
type FalsyType = false | null | undefined;
|
||||
export declare function strictObjectKeys<O extends object>(o: O): (keyof O)[];
|
||||
export declare function objectsEqual(a: unknown, b: unknown): boolean;
|
||||
export declare function objectsEqualWith<T extends PlainObject>(a: T, b: T, cmp: (a: T, b: T) => boolean): boolean;
|
||||
/**
|
||||
* Merge objects from left to right, with left-most properties having highest precedent.
|
||||
*
|
||||
* NOTE: `undefined` values take lower priority than actual values irrespective of precedent.
|
||||
*/
|
||||
export declare function mergeDefaults<TSource extends PlainObject, TArgs extends (TSource | FalsyType)[]>(...sources: TArgs): Intersection<Exclude<TArgs[number], FalsyType>>;
|
||||
export declare function mergeDefaults<TSameSource extends PlainObject>(...sources: (TSameSource | undefined)[]): TSameSource;
|
||||
/**
|
||||
* Merge objects from left to right, with left-most properties having highest precedent.
|
||||
*/
|
||||
export declare function merge<TSource extends PlainObject, TArgs extends (TSource | FalsyType)[]>(...sources: TArgs): Intersection<Exclude<TArgs[number], FalsyType>>;
|
||||
export declare function mergeArrayDefaults<T extends PlainObject>(dataArray: T[], ...itemDefaults: T[]): T[] | Intersection<Exclude<T, FalsyType>>[];
|
||||
export declare function mapValues<T extends PlainObject, R>(object: T, mapper: (value: T[keyof T], key: keyof T, object: T) => R): Record<keyof T, R>;
|
||||
export declare function without<T, K extends keyof T | string>(object: T | undefined, keys: readonly K[]): Omit<T, K>;
|
||||
export declare function without(object: object | undefined, keys: readonly string[]): object;
|
||||
export declare function pick<T, K extends keyof T>(object: T | undefined, keys: readonly K[]): Pick<T, K>;
|
||||
export declare function pick(object: object | undefined, keys: readonly string[]): object;
|
||||
export declare function every<T, K extends keyof T>(object: T | undefined, fn: (key: K, value: unknown) => boolean): boolean;
|
||||
export declare function every(object: object | undefined, fn: (key: string, value: unknown) => boolean): boolean;
|
||||
export declare function fromPairs<K extends string>(pairs?: Array<[K, any]>): Record<K, any>;
|
||||
export declare function getPath(object: object, path: string | string[]): any;
|
||||
export declare const SKIP_JS_BUILTINS: Set<string>;
|
||||
export declare function setPath(object: object, path: string | string[], newValue: unknown): any;
|
||||
export declare function partialAssign<T>(keysToCopy: (keyof T)[], target: T, source?: Partial<T>): T;
|
||||
export declare function assignIfNotStrictlyEqual<T extends object>(target: T, source: T): T;
|
||||
export declare function assignIfNotStrictlyEqual<T extends object>(target: T, source: T, keys: readonly string[]): T;
|
||||
export declare function deepFreeze<T>(obj: T): T;
|
||||
export declare function isObjectWithProperty<K extends string>(obj: unknown, key: K): obj is {
|
||||
[key in K]: unknown;
|
||||
};
|
||||
export declare function isObjectWithStringProperty<K extends string>(obj: unknown, key: K): obj is {
|
||||
[key in K]: string;
|
||||
};
|
||||
export {};
|
||||
47
node_modules/ag-charts-core/dist/types/src/utils/data/strings.d.ts
generated
vendored
Executable file
47
node_modules/ag-charts-core/dist/types/src/utils/data/strings.d.ts
generated
vendored
Executable file
@@ -0,0 +1,47 @@
|
||||
import type { TextOrSegments } from 'ag-charts-types';
|
||||
/**
|
||||
* Joins an array of strings or objects into a formatted string, adding a custom conjunction before the last item.
|
||||
* Useful for creating human-readable lists from arrays with an option to limit the number of items shown.
|
||||
* @param values An array of strings or objects to join. Objects are converted to strings using the `format` function.
|
||||
* @param conjunction The word to use before the last item in the list, defaulting to 'and'.
|
||||
* @param format A function that formats each item in the array. By default, items are converted to strings using `String`.
|
||||
* @param maxItems The maximum number of items to show before truncating, defaults to showing all items.
|
||||
* @returns A string that is the result of joining the formatted values with commas, truncating if necessary, and appending the specified conjunction before the last item.
|
||||
*/
|
||||
export declare function joinFormatted(values: string[], conjunction?: string, format?: (value: any) => string, maxItems?: number): string;
|
||||
/**
|
||||
* Converts a value to a string with an optional maximum length.
|
||||
* Provides specific string representations for `undefined`, `NaN`, `Infinity`, and `-Infinity`.
|
||||
* If the stringified value exceeds the specified maximum length, it truncates the string and appends an indication of the truncated length.
|
||||
* @param value The value to be stringified. Can be of any type.
|
||||
* @param maxLength The maximum length of the resulting string. Defaults to Infinity.
|
||||
* @returns A string representation of the value, potentially truncated if it exceeds the maximum length.
|
||||
*/
|
||||
export declare function stringifyValue(value: unknown, maxLength?: number): string;
|
||||
/**
|
||||
* Efficiently counts the number of lines in a string.
|
||||
* Processes the string in a single pass, counting newline (`\n`) characters
|
||||
* by their ASCII value (10). Optimized for performance in scenarios with
|
||||
* large datasets or tight loops.
|
||||
* @param {string} text The input string.
|
||||
* @returns {number} The number of lines, with at least one line for non-empty strings.
|
||||
*/
|
||||
export declare function countLines(text: string): number;
|
||||
/**
|
||||
* Computes the Levenshtein distance between two strings.
|
||||
* This function uses a space-optimized dynamic programming approach.
|
||||
*
|
||||
* @param {string} a - The first string.
|
||||
* @param {string} b - The second string.
|
||||
* @returns {number} - The Levenshtein distance between the two strings.
|
||||
*/
|
||||
export declare function levenshteinDistance(a: string, b: string): number;
|
||||
/**
|
||||
* Converts a string into kebab-case. It lowercases each matched uppercase character in the same single iteration
|
||||
* through the string.
|
||||
*
|
||||
* @param {string} a - The string.
|
||||
* @returns {string} - The kebab-case string.
|
||||
*/
|
||||
export declare function kebabCase(a: string): string;
|
||||
export declare function toPlainText(text?: TextOrSegments, fallback?: string): string;
|
||||
21
node_modules/ag-charts-core/dist/types/src/utils/data/value.d.ts
generated
vendored
Executable file
21
node_modules/ag-charts-core/dist/types/src/utils/data/value.d.ts
generated
vendored
Executable file
@@ -0,0 +1,21 @@
|
||||
import type { PlainObject } from '../../types/global';
|
||||
type StringObject = PlainObject & {
|
||||
toString: () => string;
|
||||
};
|
||||
type NumberObject = PlainObject & {
|
||||
valueOf: () => number;
|
||||
};
|
||||
export declare function isStringObject(value: unknown): value is StringObject;
|
||||
export declare function isNumberObject(value: unknown): value is NumberObject;
|
||||
export declare function isContinuous(value: unknown): value is number | Date | NumberObject;
|
||||
export declare function checkDatum<T>(value: T, isContinuousScale: boolean): boolean;
|
||||
/**
|
||||
* To enable duplicate categories, a category axis value on a datum from integrated charts is transformed into an
|
||||
* object with `getString()` and `id` properties. The string value can be non-unique so we must instead use the
|
||||
* unique id property.
|
||||
*
|
||||
* @see https://ag-grid.atlassian.net/browse/AG-10526
|
||||
*/
|
||||
export declare function transformIntegratedCategoryValue(value: unknown): any;
|
||||
export declare function readIntegratedWrappedValue<D>(value: D): D;
|
||||
export {};
|
||||
1
node_modules/ag-charts-core/dist/types/src/utils/data/visibleRange.d.ts
generated
vendored
Executable file
1
node_modules/ag-charts-core/dist/types/src/utils/data/visibleRange.d.ts
generated
vendored
Executable file
@@ -0,0 +1 @@
|
||||
export declare function rescaleVisibleRange(visibleRange: [number, number], [s0, s1]: [number, number], [d0, d1]: [number, number]): [number, number];
|
||||
5
node_modules/ag-charts-core/dist/types/src/utils/deprecation.d.ts
generated
vendored
Executable file
5
node_modules/ag-charts-core/dist/types/src/utils/deprecation.d.ts
generated
vendored
Executable file
@@ -0,0 +1,5 @@
|
||||
export declare function createDeprecationWarning(): (key: string, message?: string) => void;
|
||||
export declare function Deprecated(message?: string, opts?: {
|
||||
default?: any;
|
||||
}): PropertyDecorator;
|
||||
export declare function DeprecatedAndRenamedTo(newPropName: any, mapValue?: (value: any) => any): PropertyDecorator;
|
||||
59
node_modules/ag-charts-core/dist/types/src/utils/dom/attributeUtil.d.ts
generated
vendored
Executable file
59
node_modules/ag-charts-core/dist/types/src/utils/dom/attributeUtil.d.ts
generated
vendored
Executable file
@@ -0,0 +1,59 @@
|
||||
import type { Direction } from 'ag-charts-types';
|
||||
import type { Nullable } from '../../types/global';
|
||||
import type { ElementID } from '../../types/idBranding';
|
||||
export type StrictHTMLElement = HTMLElement & {
|
||||
id: ElementID;
|
||||
};
|
||||
type AriaRole = 'figure' | 'group' | 'img' | 'list' | 'listitem' | 'menu' | 'menuitem' | 'menuitemradio' | 'presentation' | 'radio' | 'radiogroup' | 'separator' | 'status' | 'switch' | 'tab' | 'tablist' | 'tabpanel' | 'textbox' | 'toolbar';
|
||||
export type BaseAttributeTypeMap = {
|
||||
role: AriaRole;
|
||||
'aria-checked': boolean;
|
||||
'aria-controls': ElementID;
|
||||
'aria-describedby': ElementID;
|
||||
'aria-disabled': boolean;
|
||||
'aria-expanded': boolean;
|
||||
'aria-haspopup': 'true' | 'false' | 'menu' | 'dialog' | 'grid' | 'listbox' | 'tree';
|
||||
'aria-hidden': boolean;
|
||||
'aria-label': string;
|
||||
'aria-labelledby': ElementID;
|
||||
'aria-live': 'assertive' | 'polite';
|
||||
'aria-orientation': Direction;
|
||||
'aria-selected': boolean;
|
||||
'data-focus-override': boolean;
|
||||
'data-focus-visible-override': boolean;
|
||||
'data-preventdefault': boolean;
|
||||
class: string;
|
||||
for: ElementID;
|
||||
id: ElementID;
|
||||
tabindex: 0 | -1;
|
||||
title: string;
|
||||
};
|
||||
type InputAttributeTypeMap = BaseAttributeTypeMap & {
|
||||
placeholder: string;
|
||||
};
|
||||
export type AttributeSet = Partial<{
|
||||
[K in keyof BaseAttributeTypeMap]: BaseAttributeTypeMap[K];
|
||||
}>;
|
||||
export type InputAttributeSet = Partial<{
|
||||
[K in keyof InputAttributeTypeMap]: InputAttributeTypeMap[K];
|
||||
}>;
|
||||
export type BaseStyleTypeMap = {
|
||||
cursor: 'default' | 'pointer' | 'ew-resize' | 'ns-resize' | 'grab' | 'grabbing';
|
||||
display: 'none';
|
||||
position: 'absolute';
|
||||
'pointer-events': 'auto' | 'none';
|
||||
width: '100%';
|
||||
height: '100%';
|
||||
};
|
||||
type StyleSet = Partial<{
|
||||
[K in keyof BaseStyleTypeMap]: BaseStyleTypeMap[K];
|
||||
}>;
|
||||
export declare function setAttribute<A extends keyof BaseAttributeTypeMap>(e: Nullable<HTMLElement>, qualifiedName: A, value: BaseAttributeTypeMap[A] | undefined): void;
|
||||
export declare function setAttribute<A extends keyof InputAttributeTypeMap>(e: Nullable<HTMLTextAreaElement>, qualifiedName: A, value: InputAttributeTypeMap[A] | undefined): void;
|
||||
export declare function setAttributes(e: Nullable<HTMLElement>, attrs: AttributeSet | undefined): void;
|
||||
export declare function setAttributes(e: Nullable<HTMLTextAreaElement>, attrs: InputAttributeTypeMap | undefined): void;
|
||||
export declare function getAttribute<A extends keyof BaseAttributeTypeMap, DefaultType extends BaseAttributeTypeMap[A] | undefined>(e: Nullable<HTMLElement | EventTarget>, qualifiedName: A, defaultValue?: DefaultType): BaseAttributeTypeMap[A] | (DefaultType extends undefined ? undefined : never);
|
||||
export declare function getAttribute<A extends keyof InputAttributeTypeMap, DefaultType extends InputAttributeTypeMap[A] | undefined>(e: Nullable<HTMLTextAreaElement>, qualifiedName: A, defaultValue?: DefaultType): InputAttributeTypeMap[A] | (DefaultType extends undefined ? undefined : never);
|
||||
export declare function setElementStyle<P extends keyof BaseStyleTypeMap>(e: Nullable<Pick<HTMLElement, 'style'>>, property: P, value: BaseStyleTypeMap[P] | undefined): void;
|
||||
export declare function setElementStyles(e: Nullable<HTMLElement>, styles: StyleSet): void;
|
||||
export {};
|
||||
6
node_modules/ag-charts-core/dist/types/src/utils/dom/domDownload.d.ts
generated
vendored
Executable file
6
node_modules/ag-charts-core/dist/types/src/utils/dom/domDownload.d.ts
generated
vendored
Executable file
@@ -0,0 +1,6 @@
|
||||
/**
|
||||
* Triggers a download for a given data URL and file name.
|
||||
* @param dataUrl - The data URL of the file to download.
|
||||
* @param fileName - The name of the file to be saved.
|
||||
*/
|
||||
export declare function downloadUrl(dataUrl: string, fileName: string): void;
|
||||
16
node_modules/ag-charts-core/dist/types/src/utils/dom/domElements.d.ts
generated
vendored
Executable file
16
node_modules/ag-charts-core/dist/types/src/utils/dom/domElements.d.ts
generated
vendored
Executable file
@@ -0,0 +1,16 @@
|
||||
import type { StrictHTMLElement } from './attributeUtil';
|
||||
/**
|
||||
* Creates an HTML element with optional class names and inline styles.
|
||||
* @param tagName - The name of the HTML element to create.
|
||||
* @param className - A space-separated string of class names or a style object (optional).
|
||||
* @param style - An object representing CSS styles (optional).
|
||||
* @returns The created HTML element.
|
||||
*/
|
||||
export declare function createElement<K extends keyof HTMLElementTagNameMap>(tagName: K, className?: string, style?: Partial<CSSStyleDeclaration>): HTMLElementTagNameMap[K] & StrictHTMLElement;
|
||||
export declare function createElement<K extends keyof HTMLElementTagNameMap>(tagName: K, style?: Partial<CSSStyleDeclaration>): HTMLElementTagNameMap[K] & StrictHTMLElement;
|
||||
/**
|
||||
* Creates an SVG element.
|
||||
* @param elementName - The name of the SVG element to create.
|
||||
* @returns The created SVG element.
|
||||
*/
|
||||
export declare function createSvgElement<K extends keyof SVGElementTagNameMap>(elementName: K): SVGElementTagNameMap[K];
|
||||
3
node_modules/ag-charts-core/dist/types/src/utils/dom/domEvents.d.ts
generated
vendored
Executable file
3
node_modules/ag-charts-core/dist/types/src/utils/dom/domEvents.d.ts
generated
vendored
Executable file
@@ -0,0 +1,3 @@
|
||||
type EventMapFor<T> = T extends Window ? WindowEventMap : T extends Document ? DocumentEventMap : T extends HTMLElement ? HTMLElementEventMap : never;
|
||||
export declare function attachListener<T extends Document | HTMLElement | Window, K extends keyof EventMapFor<T>>(element: T, eventName: K & string, handler: (this: T, event: EventMapFor<T>[K]) => void, options?: boolean | AddEventListenerOptions): () => void;
|
||||
export {};
|
||||
7
node_modules/ag-charts-core/dist/types/src/utils/dom/domUtil.d.ts
generated
vendored
Executable file
7
node_modules/ag-charts-core/dist/types/src/utils/dom/domUtil.d.ts
generated
vendored
Executable file
@@ -0,0 +1,7 @@
|
||||
import type { AgIconName } from 'ag-charts-types';
|
||||
import type { BoxBounds } from '../geometry/boxBounds';
|
||||
export declare function setElementBBox(element: HTMLElement | undefined, bbox: Partial<BoxBounds>): void;
|
||||
export declare function getElementBBox(element: HTMLElement): BoxBounds;
|
||||
export declare function focusCursorAtEnd(element: HTMLElement): void;
|
||||
export declare function isInputPending(): false | void;
|
||||
export declare function getIconClassNames(icon: AgIconName): string;
|
||||
1
node_modules/ag-charts-core/dist/types/src/utils/dom/domUtils.d.ts
generated
vendored
Executable file
1
node_modules/ag-charts-core/dist/types/src/utils/dom/domUtils.d.ts
generated
vendored
Executable file
@@ -0,0 +1 @@
|
||||
export declare function parseColor(color: string): string | null;
|
||||
71
node_modules/ag-charts-core/dist/types/src/utils/dom/globalsProxy.d.ts
generated
vendored
Executable file
71
node_modules/ag-charts-core/dist/types/src/utils/dom/globalsProxy.d.ts
generated
vendored
Executable file
@@ -0,0 +1,71 @@
|
||||
/**
|
||||
* Retrieves the global `document` object or a specific property of it.
|
||||
* @param propertyName - The name of the `document` property to retrieve (optional).
|
||||
* @returns The `document` object or the specified property.
|
||||
*/
|
||||
export declare function getDocument<E>(): Document & E;
|
||||
export declare function getDocument<K extends keyof Document>(propertyName: K): Document[K];
|
||||
/**
|
||||
* Retrieves the global `window` object or a specific property of it.
|
||||
* @param propertyName - The name of the `window` property to retrieve (optional).
|
||||
* @returns The `window` object or the specified property.
|
||||
*/
|
||||
export declare function getWindow<E>(): Window & E;
|
||||
export declare function getWindow<K extends keyof Window>(propertyName: K): Window[K];
|
||||
export declare function getWindow<R = unknown>(propertyName: string): R;
|
||||
/**
|
||||
* Sets the global `document` object.
|
||||
* @param document - The `document` object to set.
|
||||
*/
|
||||
export declare function setDocument(document: Document): void;
|
||||
/**
|
||||
* Sets the global `window` object.
|
||||
* @param window - The `window` object to set.
|
||||
*/
|
||||
export declare function setWindow(window: Window): void;
|
||||
/**
|
||||
* Retrieves the OffscreenCanvas constructor from the injected window.
|
||||
* Falls back to globalThis if window doesn't have it.
|
||||
*/
|
||||
export declare function getOffscreenCanvas(): typeof OffscreenCanvas;
|
||||
/**
|
||||
* Retrieves the Path2D constructor from the injected window.
|
||||
* Falls back to globalThis if window doesn't have it.
|
||||
*/
|
||||
export declare function getPath2D(): typeof Path2D;
|
||||
/**
|
||||
* Retrieves the DOMMatrix constructor from the injected window.
|
||||
* Falls back to globalThis if window doesn't have it.
|
||||
*/
|
||||
export declare function getDOMMatrix(): typeof DOMMatrix;
|
||||
/**
|
||||
* Retrieves the Image constructor from the injected window.
|
||||
* Falls back to globalThis if window doesn't have it.
|
||||
*/
|
||||
export declare function getImage(): typeof HTMLImageElement;
|
||||
/**
|
||||
* Retrieves the ResizeObserver constructor from the injected window.
|
||||
* Falls back to globalThis if window doesn't have it.
|
||||
* Returns undefined in SSR environments without a polyfill.
|
||||
*/
|
||||
export declare function getResizeObserver(): typeof ResizeObserver | undefined;
|
||||
/**
|
||||
* SSR-safe check for whether an object is a DOM Node.
|
||||
* Uses duck-typing via nodeType property instead of instanceof.
|
||||
*/
|
||||
export declare function isNode(obj: unknown): obj is Node;
|
||||
/**
|
||||
* SSR-safe check for whether an object is a DOM Element.
|
||||
* Uses duck-typing via nodeType property instead of instanceof.
|
||||
*/
|
||||
export declare function isElement(obj: unknown): obj is Element;
|
||||
/**
|
||||
* SSR-safe check for whether an object is a DocumentFragment (e.g. Shadow DOM root).
|
||||
* Uses duck-typing via nodeType property instead of instanceof.
|
||||
*/
|
||||
export declare function isDocumentFragment(obj: unknown): obj is DocumentFragment;
|
||||
/**
|
||||
* SSR-safe check for whether an object is an HTMLElement.
|
||||
* Uses duck-typing via nodeType and style property instead of instanceof.
|
||||
*/
|
||||
export declare function isHTMLElement(obj: unknown): obj is HTMLElement;
|
||||
28
node_modules/ag-charts-core/dist/types/src/utils/dom/keynavUtil.d.ts
generated
vendored
Executable file
28
node_modules/ag-charts-core/dist/types/src/utils/dom/keynavUtil.d.ts
generated
vendored
Executable file
@@ -0,0 +1,28 @@
|
||||
import { CleanupRegistry } from '../../state/cleanupRegistry';
|
||||
export declare function addEscapeEventListener(elem: HTMLElement, onEscape: (event: KeyboardEvent) => void, keyCodes?: readonly string[]): () => void;
|
||||
export declare function addMouseCloseListener(menu: HTMLElement, hideCallback: () => void): () => void;
|
||||
export declare function addTouchCloseListener(menu: HTMLElement, hideCallback: () => void): () => void;
|
||||
export declare function addOverrideFocusVisibleEventListener(menu: HTMLElement, buttons: HTMLElement[], overrideFocusVisible: boolean): () => void;
|
||||
export declare function hasNoModifiers(event: KeyboardEvent | MouseEvent): boolean;
|
||||
export declare const PREV_NEXT_KEYS: {
|
||||
readonly horizontal: {
|
||||
readonly nextKey: "ArrowRight";
|
||||
readonly prevKey: "ArrowLeft";
|
||||
};
|
||||
readonly vertical: {
|
||||
readonly nextKey: "ArrowDown";
|
||||
readonly prevKey: "ArrowUp";
|
||||
};
|
||||
};
|
||||
export declare function initRovingTabIndex(opts: {
|
||||
orientation: 'horizontal' | 'vertical';
|
||||
buttons: HTMLElement[];
|
||||
wrapAround?: boolean;
|
||||
onFocus?: (event: FocusEvent) => void;
|
||||
onBlur?: (event: FocusEvent) => void;
|
||||
onEscape?: (event: KeyboardEvent) => void;
|
||||
}): CleanupRegistry;
|
||||
export declare function makeAccessibleClickListener(element: HTMLElement, onclick: (event: MouseEvent) => unknown): (event: MouseEvent) => void;
|
||||
export declare function isButtonClickEvent(event: KeyboardEvent | MouseEvent): boolean;
|
||||
export declare function getLastFocus(sourceEvent: Event | undefined): HTMLElement | undefined;
|
||||
export declare function stopPageScrolling(element: HTMLElement): () => void;
|
||||
79
node_modules/ag-charts-core/dist/types/src/utils/format/color.d.ts
generated
vendored
Executable file
79
node_modules/ag-charts-core/dist/types/src/utils/format/color.d.ts
generated
vendored
Executable file
@@ -0,0 +1,79 @@
|
||||
interface IColor {
|
||||
readonly r: number;
|
||||
readonly g: number;
|
||||
readonly b: number;
|
||||
readonly a: number;
|
||||
}
|
||||
export declare class Color implements IColor {
|
||||
readonly r: number;
|
||||
readonly g: number;
|
||||
readonly b: number;
|
||||
readonly a: number;
|
||||
/**
|
||||
* Every color component should be in the [0, 1] range.
|
||||
* Some easing functions (such as elastic easing) can overshoot the target value by some amount.
|
||||
* So, when animating colors, if the source or target color components are already near
|
||||
* or at the edge of the allowed [0, 1] range, it is possible for the intermediate color
|
||||
* component value to end up outside of that range mid-animation. For this reason the constructor
|
||||
* performs range checking/constraining.
|
||||
* @param r Red component.
|
||||
* @param g Green component.
|
||||
* @param b Blue component.
|
||||
* @param a Alpha (opacity) component.
|
||||
*/
|
||||
constructor(r: number, g: number, b: number, a?: number);
|
||||
/**
|
||||
* A color string can be in one of the following formats to be valid:
|
||||
* - #rgb
|
||||
* - #rrggbb
|
||||
* - rgb(r, g, b)
|
||||
* - rgba(r, g, b, a)
|
||||
* - CSS color name such as 'white', 'orange', 'cyan', etc.
|
||||
*/
|
||||
static validColorString(str: string): boolean;
|
||||
/**
|
||||
* The given string can be in one of the following formats:
|
||||
* - #rgb
|
||||
* - #rrggbb
|
||||
* - rgb(r, g, b)
|
||||
* - rgba(r, g, b, a)
|
||||
* - CSS color name such as 'white', 'orange', 'cyan', etc.
|
||||
* @param str
|
||||
*/
|
||||
static fromString(str: string): Color;
|
||||
static parseHex(input: string): [number, number, number, number] | undefined;
|
||||
static fromHexString(str: string): Color;
|
||||
private static stringToRgba;
|
||||
static fromRgbaString(str: string): Color;
|
||||
static fromArray(arr: [number, number, number] | [number, number, number, number]): Color;
|
||||
static fromHSB(h: number, s: number, b: number, alpha?: number): Color;
|
||||
static fromHSL(h: number, s: number, l: number, alpha?: number): Color;
|
||||
static fromOKLCH(l: number, c: number, h: number, alpha?: number): Color;
|
||||
private static padHex;
|
||||
toHexString(): string;
|
||||
toRgbaString(fractionDigits?: number): string;
|
||||
toString(): string;
|
||||
toHSB(): [number, number, number];
|
||||
static RGBtoOKLCH(r: number, g: number, b: number): [number, number, number];
|
||||
static OKLCHtoRGB(l: number, c: number, h: number): [number, number, number];
|
||||
static RGBtoHSL(r: number, g: number, b: number): [number, number, number];
|
||||
static HSLtoRGB(h: number, s: number, l: number): [number, number, number];
|
||||
/**
|
||||
* Converts the given RGB triple to an array of HSB (HSV) components.
|
||||
*/
|
||||
static RGBtoHSB(r: number, g: number, b: number): [number, number, number];
|
||||
/**
|
||||
* Converts the given HSB (HSV) triple to an array of RGB components.
|
||||
*/
|
||||
static HSBtoRGB(H: number, S: number, B: number): [number, number, number];
|
||||
static mix(c0: Color, c1: Color, t: number): Color;
|
||||
static lighten(c: Color, t: number): Color;
|
||||
static darken(c: Color, t: number): Color;
|
||||
static interpolate(colors: Color[], count: number): Color[];
|
||||
/**
|
||||
* CSS Color Module Level 4:
|
||||
* https://drafts.csswg.org/css-color/#named-colors
|
||||
*/
|
||||
private static readonly nameToHex;
|
||||
}
|
||||
export {};
|
||||
29
node_modules/ag-charts-core/dist/types/src/utils/format/format.util.d.ts
generated
vendored
Executable file
29
node_modules/ag-charts-core/dist/types/src/utils/format/format.util.d.ts
generated
vendored
Executable file
@@ -0,0 +1,29 @@
|
||||
/**
|
||||
* Formats a value as a string. If the value is a number, it formats it with the specified
|
||||
* maximum number of fraction digits. If the value is not a number, it returns an empty string
|
||||
* or the string representation of the value.
|
||||
*
|
||||
* @param value - The value to format.
|
||||
* @param maximumFractionDigits - The maximum number of fraction digits to display when formatting numbers.
|
||||
* @returns A formatted string representation of the value.
|
||||
*/
|
||||
export declare function formatValue(value: unknown, maximumFractionDigits?: number): string;
|
||||
/**
|
||||
* Formats a number as a percentage using the current locale.
|
||||
*
|
||||
* @param value - A decimal number representing the percentage (e.g., 0.25 for 25%).
|
||||
* @returns A percentage string.
|
||||
*/
|
||||
export declare function formatPercent(value: number): string;
|
||||
/**
|
||||
* Formats a number with a specified maximum number of fraction digits.
|
||||
*
|
||||
* This function improves upon `Number.toFixed(n)`, which always displays exactly `n` digits after the decimal point.
|
||||
* Instead, this function limits the number of fraction digits to a maximum value, making it useful for
|
||||
* displaying both small and large numbers with an appropriate level of precision.
|
||||
*
|
||||
* @param value - The number to format.
|
||||
* @param maximumFractionDigits - The maximum number of fraction digits to display.
|
||||
* @returns A string representing the formatted number.
|
||||
*/
|
||||
export declare function formatNumber(value: number, maximumFractionDigits: number): string;
|
||||
19
node_modules/ag-charts-core/dist/types/src/utils/format/numberFormat.d.ts
generated
vendored
Executable file
19
node_modules/ag-charts-core/dist/types/src/utils/format/numberFormat.d.ts
generated
vendored
Executable file
@@ -0,0 +1,19 @@
|
||||
interface FormatterOptions {
|
||||
prefix?: string;
|
||||
fill?: string;
|
||||
align?: string;
|
||||
sign?: string;
|
||||
symbol?: string;
|
||||
zero?: string;
|
||||
width?: number;
|
||||
comma?: string;
|
||||
precision?: number;
|
||||
trim?: boolean;
|
||||
type?: string;
|
||||
suffix?: string;
|
||||
}
|
||||
export declare function isValidNumberFormat(value: unknown): boolean;
|
||||
export declare function parseNumberFormat(format: string): FormatterOptions | undefined;
|
||||
export declare function createNumberFormatter(format: FormatterOptions): (n: number, fractionDigits?: number) => string;
|
||||
export declare function createNumberFormatter(format: string): ((n: number, fractionDigits?: number) => string) | undefined;
|
||||
export {};
|
||||
3
node_modules/ag-charts-core/dist/types/src/utils/format/timeFormat.d.ts
generated
vendored
Executable file
3
node_modules/ag-charts-core/dist/types/src/utils/format/timeFormat.d.ts
generated
vendored
Executable file
@@ -0,0 +1,3 @@
|
||||
type FormattingFn = (dateTime: Date, paddingChar?: string) => string;
|
||||
export declare function buildDateFormatter(formatString: string): FormattingFn;
|
||||
export {};
|
||||
43
node_modules/ag-charts-core/dist/types/src/utils/functions.d.ts
generated
vendored
Executable file
43
node_modules/ag-charts-core/dist/types/src/utils/functions.d.ts
generated
vendored
Executable file
@@ -0,0 +1,43 @@
|
||||
interface DebounceOptions {
|
||||
leading?: boolean;
|
||||
trailing?: boolean;
|
||||
maxWait?: number;
|
||||
}
|
||||
interface ThrottleOptions {
|
||||
leading?: boolean;
|
||||
trailing?: boolean;
|
||||
}
|
||||
/**
|
||||
* Creates a debounced function that delays invoking the provided callback until
|
||||
* after `waitMs` milliseconds have elapsed since the last time the function was called.
|
||||
*
|
||||
* @template T - The type of the callback function.
|
||||
* @param callback - The function to debounce.
|
||||
* @param waitMs - The number of milliseconds to delay (default is 0).
|
||||
* @param options - Optional configuration:
|
||||
* - `leading` (default: false): If true, the callback will be invoked on the leading edge of the timeout.
|
||||
* - `trailing` (default: true): If true, the callback will be invoked on the trailing edge of the timeout.
|
||||
* - `maxWait` (default: Infinity): The maximum time the callback can be delayed before it's invoked.
|
||||
* @returns A debounced version of the callback with a `cancel` method to clear the timer.
|
||||
* @throws If `maxWait` is less than `waitMs`.
|
||||
*/
|
||||
export declare function debounce<T extends (...args: Parameters<T>) => void>(callback: T, waitMs?: number, options?: DebounceOptions): ((...args: Parameters<T>) => void) & {
|
||||
cancel(): void;
|
||||
};
|
||||
/**
|
||||
* Creates a throttled function that only invokes the provided callback at most once
|
||||
* every `waitMs` milliseconds.
|
||||
*
|
||||
* @template T - The type of the callback function.
|
||||
* @param callback - The function to throttle.
|
||||
* @param waitMs - The number of milliseconds to throttle invocations.
|
||||
* @param options - Optional configuration:
|
||||
* - `leading` (default: true): If true, the callback will be invoked on the leading edge of the timeout.
|
||||
* - `trailing` (default: true): If true, the callback will be invoked on the trailing edge of the timeout.
|
||||
* @returns A throttled version of the callback with a `cancel` method to clear the timer.
|
||||
*/
|
||||
export declare function throttle<T extends (...args: Parameters<T>) => void>(callback: T, waitMs: number, options?: ThrottleOptions): ((...args: Parameters<T>) => void) & {
|
||||
cancel(): void;
|
||||
};
|
||||
export declare function safeCall<T = unknown>(callback: Function, args: any[], errorPath?: string): T | undefined;
|
||||
export {};
|
||||
1
node_modules/ag-charts-core/dist/types/src/utils/geojson.d.ts
generated
vendored
Executable file
1
node_modules/ag-charts-core/dist/types/src/utils/geojson.d.ts
generated
vendored
Executable file
@@ -0,0 +1 @@
|
||||
export declare const geoJson: import("../state/validation").Validator;
|
||||
33
node_modules/ag-charts-core/dist/types/src/utils/geometry/angle.d.ts
generated
vendored
Executable file
33
node_modules/ag-charts-core/dist/types/src/utils/geometry/angle.d.ts
generated
vendored
Executable file
@@ -0,0 +1,33 @@
|
||||
/**
|
||||
* Normalize the given angle to be in the [0, 2π) interval.
|
||||
* @param radians Angle in radians.
|
||||
*/
|
||||
export declare function normalizeAngle360(radians: number): number;
|
||||
export declare function normalizeAngle360Inclusive(radians: number): number;
|
||||
/**
|
||||
* Normalize the given angle to be in the [-π, π) interval.
|
||||
* @param radians Angle in radians.
|
||||
*/
|
||||
export declare function normalizeAngle180(radians: number): number;
|
||||
export declare function isBetweenAngles(targetAngle: number, startAngle: number, endAngle: number): boolean;
|
||||
export declare function toRadians(degrees: number): number;
|
||||
export declare function toDegrees(radians: number): number;
|
||||
/**
|
||||
* Returns a rotation angle between two other angles.
|
||||
* @param angle0 Angle in radians.
|
||||
* @param angle1 Angle in radians.
|
||||
* @returns Angle in radians.
|
||||
*/
|
||||
export declare function angleBetween(angle0: number, angle1: number): number;
|
||||
/**
|
||||
* Calculates the ratio of an angle in radians based on its proximity to 0, π/2, π, or 3π/2.
|
||||
*
|
||||
* - 0 and π return ratios decreasing linearly to 0 at these angles.
|
||||
* - π/2 and 3π/2 return ratios increasing linearly to 1 at these angles.
|
||||
*
|
||||
* @param angle - The input angle in radians.
|
||||
* @returns The ratio (a number between 0 and 1).
|
||||
*/
|
||||
export declare function getAngleRatioRadians(angle: number): number;
|
||||
export declare function angularPadding(hPadding: number, vPadding: number, angle: number): number;
|
||||
export declare function normalizeAngle360FromDegrees(degrees?: number): number;
|
||||
6
node_modules/ag-charts-core/dist/types/src/utils/geometry/bezier.d.ts
generated
vendored
Executable file
6
node_modules/ag-charts-core/dist/types/src/utils/geometry/bezier.d.ts
generated
vendored
Executable file
@@ -0,0 +1,6 @@
|
||||
import type { Point } from '../../types/scene';
|
||||
export declare function evaluateBezier(p0: number, p1: number, p2: number, p3: number, t: number): number;
|
||||
export declare function solveBezier(p0: number, p1: number, p2: number, p3: number, value: number): number;
|
||||
export declare function splitBezier2D(p0x: number, p0y: number, p1x: number, p1y: number, p2x: number, p2y: number, p3x: number, p3y: number, t: number): [[Point, Point, Point, Point], [Point, Point, Point, Point]];
|
||||
export declare function bezier2DExtrema(cp0x: number, cp0y: number, cp1x: number, cp1y: number, cp2x: number, cp2y: number, cp3x: number, cp3y: number): number[];
|
||||
export declare function bezier2DDistance(cp0x: number, cp0y: number, cp1x: number, cp1y: number, cp2x: number, cp2y: number, cp3x: number, cp3y: number, x: number, y: number, precision?: number): number;
|
||||
18
node_modules/ag-charts-core/dist/types/src/utils/geometry/border.d.ts
generated
vendored
Executable file
18
node_modules/ag-charts-core/dist/types/src/utils/geometry/border.d.ts
generated
vendored
Executable file
@@ -0,0 +1,18 @@
|
||||
import type { BorderOptions } from 'ag-charts-types';
|
||||
import { BaseProperties } from '../../state/properties';
|
||||
export declare class Border extends BaseProperties implements BorderOptions {
|
||||
readonly node: {
|
||||
stroke?: string | object;
|
||||
strokeOpacity: number;
|
||||
strokeWidth: number;
|
||||
};
|
||||
enabled: boolean;
|
||||
stroke: string;
|
||||
strokeOpacity: number;
|
||||
strokeWidth: number;
|
||||
constructor(node: {
|
||||
stroke?: string | object;
|
||||
strokeOpacity: number;
|
||||
strokeWidth: number;
|
||||
});
|
||||
}
|
||||
7
node_modules/ag-charts-core/dist/types/src/utils/geometry/boxBounds.d.ts
generated
vendored
Executable file
7
node_modules/ag-charts-core/dist/types/src/utils/geometry/boxBounds.d.ts
generated
vendored
Executable file
@@ -0,0 +1,7 @@
|
||||
import type { Point, Size } from '../../types/scene';
|
||||
export interface BoxBounds extends Size, Point {
|
||||
}
|
||||
export declare function boxCollides(b: BoxBounds, x: number, y: number, w: number, h: number): boolean;
|
||||
export declare function boxContains(b: BoxBounds, x: number, y: number, w?: number, h?: number): boolean;
|
||||
export declare function boxEmpty(b: BoxBounds | undefined): boolean;
|
||||
export declare function boxesEqual(a: BoxBounds | undefined, b: BoxBounds | undefined): boolean;
|
||||
2
node_modules/ag-charts-core/dist/types/src/utils/geometry/distance.d.ts
generated
vendored
Executable file
2
node_modules/ag-charts-core/dist/types/src/utils/geometry/distance.d.ts
generated
vendored
Executable file
@@ -0,0 +1,2 @@
|
||||
export declare function lineDistanceSquared(x: number, y: number, x1: number, y1: number, x2: number, y2: number, best: number): number;
|
||||
export declare function arcDistanceSquared(x: number, y: number, cx: number, cy: number, radius: number, startAngle: number, endAngle: number, counterClockwise: boolean, best: number): number;
|
||||
8
node_modules/ag-charts-core/dist/types/src/utils/geometry/fill.d.ts
generated
vendored
Executable file
8
node_modules/ag-charts-core/dist/types/src/utils/geometry/fill.d.ts
generated
vendored
Executable file
@@ -0,0 +1,8 @@
|
||||
import type { AgImageFill, AgPatternColor } from 'ag-charts-types';
|
||||
import type { InternalAgColorType, InternalAgGradientColor } from '../../config/optionsDefaults';
|
||||
export declare function isGradientFill(fill: any): fill is InternalAgGradientColor;
|
||||
export declare function isGradientFillArray(fills: any): fills is InternalAgColorType[];
|
||||
export declare function isStringFillArray(fills: any): fills is string[];
|
||||
export declare function isPatternFill(fill: any): fill is AgPatternColor;
|
||||
export declare function isImageFill(fill: any): fill is AgImageFill;
|
||||
export declare function isGradientOrPatternFill(fill: any): fill is InternalAgGradientColor | AgPatternColor;
|
||||
27
node_modules/ag-charts-core/dist/types/src/utils/geometry/labelPlacement.d.ts
generated
vendored
Executable file
27
node_modules/ag-charts-core/dist/types/src/utils/geometry/labelPlacement.d.ts
generated
vendored
Executable file
@@ -0,0 +1,27 @@
|
||||
import type { TextOrSegments } from 'ag-charts-types';
|
||||
import type { Point, SizedPoint } from '../../types/scene';
|
||||
import { type BoxBounds } from './boxBounds';
|
||||
export type LabelPlacement = 'top' | 'bottom' | 'left' | 'right' | 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right';
|
||||
export interface MeasuredLabel {
|
||||
readonly text: TextOrSegments;
|
||||
readonly width: number;
|
||||
readonly height: number;
|
||||
}
|
||||
export interface PointLabelDatum {
|
||||
readonly point: Readonly<SizedPoint>;
|
||||
readonly label: MeasuredLabel;
|
||||
readonly anchor: Point | undefined;
|
||||
readonly placement: LabelPlacement | undefined;
|
||||
}
|
||||
export interface PlacedLabel<PLD = PointLabelDatum> extends MeasuredLabel, Readonly<Point> {
|
||||
readonly index: number;
|
||||
readonly datum: PLD;
|
||||
}
|
||||
export declare function isPointLabelDatum(x: any): x is PointLabelDatum;
|
||||
/**
|
||||
* @param data Points and labels for one or more series. The order of series determines label placement precedence.
|
||||
* @param bounds Bounds to fit the labels into. If a label can't be fully contained, it doesn't fit.
|
||||
* @param padding
|
||||
* @returns Placed labels for all series.
|
||||
*/
|
||||
export declare function placeLabels(data: Map<string, PointLabelDatum[]>, bounds: BoxBounds, padding?: number): Map<string, PlacedLabel<PointLabelDatum>[]>;
|
||||
58
node_modules/ag-charts-core/dist/types/src/utils/geometry/lineInterpolation.d.ts
generated
vendored
Executable file
58
node_modules/ag-charts-core/dist/types/src/utils/geometry/lineInterpolation.d.ts
generated
vendored
Executable file
@@ -0,0 +1,58 @@
|
||||
import type { Point } from '../../types/scene';
|
||||
export interface LinearSpan {
|
||||
type: 'linear';
|
||||
moveTo: boolean;
|
||||
x0: number;
|
||||
y0: number;
|
||||
x1: number;
|
||||
y1: number;
|
||||
}
|
||||
export interface CubicSpan {
|
||||
type: 'cubic';
|
||||
moveTo: boolean;
|
||||
cp0x: number;
|
||||
cp0y: number;
|
||||
cp1x: number;
|
||||
cp1y: number;
|
||||
cp2x: number;
|
||||
cp2y: number;
|
||||
cp3x: number;
|
||||
cp3y: number;
|
||||
}
|
||||
export interface StepSpan {
|
||||
type: 'step';
|
||||
moveTo: boolean;
|
||||
x0: number;
|
||||
y0: number;
|
||||
x1: number;
|
||||
y1: number;
|
||||
stepX: number;
|
||||
}
|
||||
export interface MultiLineSpan {
|
||||
type: 'multi-line';
|
||||
moveTo: boolean;
|
||||
x0: number;
|
||||
y0: number;
|
||||
x1: number;
|
||||
y1: number;
|
||||
midPoints: Point[];
|
||||
}
|
||||
export type Span = LinearSpan | CubicSpan | StepSpan | MultiLineSpan;
|
||||
export declare function spanRange(span: Span): [Point, Point];
|
||||
export declare function collapseSpanToPoint(span: Span, point: Point): Span;
|
||||
export declare function rescaleSpan(span: Span, nextStart: Point, nextEnd: Point): Span;
|
||||
export declare function clipSpanX(span: Span, x0: number, x1: number): Span;
|
||||
export declare enum SpanJoin {
|
||||
MoveTo = 0,
|
||||
LineTo = 1,
|
||||
Skip = 2
|
||||
}
|
||||
export declare function linearPoints(points: Iterable<Point>): Span[];
|
||||
declare const lineSteps: {
|
||||
start: number;
|
||||
middle: number;
|
||||
end: number;
|
||||
};
|
||||
export declare function stepPoints(points: Iterable<Point>, position: number | keyof typeof lineSteps): Span[];
|
||||
export declare function smoothPoints(iPoints: Iterable<Point>, tension: number): Span[];
|
||||
export {};
|
||||
1
node_modules/ag-charts-core/dist/types/src/utils/geometry/math/index.d.ts
generated
vendored
Executable file
1
node_modules/ag-charts-core/dist/types/src/utils/geometry/math/index.d.ts
generated
vendored
Executable file
@@ -0,0 +1 @@
|
||||
export * from './shapeUtils';
|
||||
23
node_modules/ag-charts-core/dist/types/src/utils/geometry/math/shapeUtils.d.ts
generated
vendored
Executable file
23
node_modules/ag-charts-core/dist/types/src/utils/geometry/math/shapeUtils.d.ts
generated
vendored
Executable file
@@ -0,0 +1,23 @@
|
||||
import type { Point, Size } from '../../../types/scene';
|
||||
/**
|
||||
* Calculates the maximum width and height of an inner rectangle that can be
|
||||
* rotated by a given angle (in degrees) and still fully fit within a container.
|
||||
*
|
||||
* @param rotationDeg - Rotation angle in degrees.
|
||||
* @param containerWidth - Width of the outer container.
|
||||
* @param containerHeight - Optional height of the container (defaults to Infinity).
|
||||
* @returns The largest inner rectangle size that fits when rotated.
|
||||
*/
|
||||
export declare function getMaxInnerRectSize(rotationDeg: number, containerWidth: number, containerHeight?: number): Size;
|
||||
/**
|
||||
* Calculates the minimum axis-aligned outer rectangle that fully contains
|
||||
* an inner rectangle of the given size when rotated by a specified angle.
|
||||
*
|
||||
* @param rotationDeg - Rotation angle in degrees.
|
||||
* @param innerWidth - Width of the inner rectangle.
|
||||
* @param innerHeight - Height of the inner rectangle (defaults to Infinity).
|
||||
* @returns The smallest outer rectangle that contains the rotated inner rectangle.
|
||||
*/
|
||||
export declare function getMinOuterRectSize(rotationDeg: number, innerWidth: number, innerHeight?: number): Size;
|
||||
export declare function rotatePoint(x: number, y: number, angle: number, // in radians
|
||||
originX?: number, originY?: number): Point;
|
||||
8
node_modules/ag-charts-core/dist/types/src/utils/geometry/padding.d.ts
generated
vendored
Executable file
8
node_modules/ag-charts-core/dist/types/src/utils/geometry/padding.d.ts
generated
vendored
Executable file
@@ -0,0 +1,8 @@
|
||||
import { BaseProperties } from '../../state/properties';
|
||||
export declare class Padding extends BaseProperties {
|
||||
top: number;
|
||||
right: number;
|
||||
bottom: number;
|
||||
left: number;
|
||||
constructor(top?: number, right?: number, bottom?: number, left?: number);
|
||||
}
|
||||
15
node_modules/ag-charts-core/dist/types/src/utils/geometry/placement.d.ts
generated
vendored
Executable file
15
node_modules/ag-charts-core/dist/types/src/utils/geometry/placement.d.ts
generated
vendored
Executable file
@@ -0,0 +1,15 @@
|
||||
export type Bounds = {
|
||||
top?: number;
|
||||
right?: number;
|
||||
bottom?: number;
|
||||
left?: number;
|
||||
width?: number;
|
||||
height?: number;
|
||||
};
|
||||
export type Placement = {
|
||||
x: number;
|
||||
y: number;
|
||||
width: number;
|
||||
height: number;
|
||||
};
|
||||
export declare function calculatePlacement(naturalWidth: number, naturalHeight: number, container: Pick<DOMRect, 'width' | 'height'>, bounds: Bounds): Placement;
|
||||
31
node_modules/ag-charts-core/dist/types/src/utils/geometry/scaling.d.ts
generated
vendored
Executable file
31
node_modules/ag-charts-core/dist/types/src/utils/geometry/scaling.d.ts
generated
vendored
Executable file
@@ -0,0 +1,31 @@
|
||||
export type Scaling = ContinuousScaling | CategoryScaling | LogScaling;
|
||||
export interface ContinuousScaling<T = 'continuous'> {
|
||||
type: T;
|
||||
domain: [number, number];
|
||||
range: [number, number];
|
||||
}
|
||||
export interface LogScaling extends ContinuousScaling<'log'> {
|
||||
convert(domain: number): number;
|
||||
}
|
||||
/** Standard category scaling with full domain array */
|
||||
export interface StandardCategoryScaling {
|
||||
type: 'category';
|
||||
domain: readonly string[] | readonly Date[];
|
||||
inset: number;
|
||||
step: number;
|
||||
}
|
||||
/** Optimized scaling for unit-time with O(1) numeric metadata instead of full domain array */
|
||||
export interface UnitTimeCategoryScaling {
|
||||
type: 'category';
|
||||
variant: 'unit-time';
|
||||
firstBandTime: number;
|
||||
lastBandTime: number;
|
||||
bandCount: number;
|
||||
intervalMs: number;
|
||||
inset: number;
|
||||
step: number;
|
||||
}
|
||||
export type CategoryScaling = StandardCategoryScaling | UnitTimeCategoryScaling;
|
||||
export declare function isUnitTimeCategoryScaling(scaling: CategoryScaling): scaling is UnitTimeCategoryScaling;
|
||||
export declare function areScalingEqual(a: Scaling | undefined, b: Scaling | undefined): boolean;
|
||||
export declare function isScaleValid(scale?: Scaling): boolean;
|
||||
118
node_modules/ag-charts-core/dist/types/src/utils/geometry/vector.d.ts
generated
vendored
Executable file
118
node_modules/ag-charts-core/dist/types/src/utils/geometry/vector.d.ts
generated
vendored
Executable file
@@ -0,0 +1,118 @@
|
||||
import type { Bounds4, Point } from '../../types/scene';
|
||||
/**
|
||||
* Add the components of the vectors `a` and `b`.
|
||||
*/
|
||||
export declare function add(a: Point, b: Point): Point;
|
||||
export declare function add(a: Point, b: number): Point;
|
||||
/**
|
||||
* Subtract the components of `b` from `a`.
|
||||
*/
|
||||
export declare function sub(a: Point, b: Point): Point;
|
||||
export declare function sub(a: Point, b: number): Point;
|
||||
/**
|
||||
* Multiply the components of `a` and `b`.
|
||||
*/
|
||||
export declare function multiply(a: Point, b: Point): Point;
|
||||
export declare function multiply(a: Point, b: number): Point;
|
||||
/**
|
||||
* Get the length of a vector.
|
||||
*/
|
||||
export declare function length(a: Point): number;
|
||||
/**
|
||||
* Get the squared length of a vector. This method is faster than `length(a)` and is useful when making comparisons
|
||||
* where the precise length does not matter.
|
||||
*/
|
||||
export declare function lengthSquared(a: Point): number;
|
||||
/**
|
||||
* Get the distance between two vectors.
|
||||
*/
|
||||
export declare function distance(a: Point, b: Point): number;
|
||||
/**
|
||||
* Get the squared distance between two vectors. This method is faster than `distance(a, b)` and is useful when making
|
||||
* comparisons where the precise distance does not matter.
|
||||
*/
|
||||
export declare function distanceSquared(a: Point, b: Point): number;
|
||||
/**
|
||||
* Normalize a vector so that each component is a value between 0 and 1 and the length of the vector is always 1.
|
||||
*/
|
||||
export declare function normalized(a: Point): Point;
|
||||
/**
|
||||
* Find the angle between two vectors.
|
||||
*/
|
||||
export declare function angle(a: Point, b?: Point): number;
|
||||
/**
|
||||
* Rotate vector `a` by the angle `theta` around the origin `b`.
|
||||
* This rotation is not cumulative, i.e. `rotate(rotate(a, Math.PI), Math.PI) !== a`.
|
||||
*/
|
||||
export declare function rotate(a: Point, theta: number, b?: Point): Point;
|
||||
/**
|
||||
* Get the gradient of the line that intersects two points.
|
||||
* Optionally reflect the line about the y-axis when the coordinate system has y = 0 at the top.
|
||||
*/
|
||||
export declare function gradient(a: Point, b: Point, reflection?: number): number;
|
||||
/**
|
||||
* Get the y-intercept of a line through a point with a gradient where `c = y - mx`.
|
||||
* Optionally reflect the line about the y-axis when the coordinate system has y = 0 at the top.
|
||||
*/
|
||||
export declare function intercept(a: Point, gradient: number, reflection?: number): number;
|
||||
/**
|
||||
* Get the point where a line intersects a horizontal line at the given y value.
|
||||
* Optionally reflect the line about the y-axis when the coordinate system has y = 0 at the top.
|
||||
*/
|
||||
export declare function intersectAtY(gradient: number, coefficient: number, y?: number, reflection?: number): Point;
|
||||
/**
|
||||
* Get the point where a line intersects a vertical line at the given x value.
|
||||
* Optionally reflect the line about the y-axis when the coordinate system has y = 0 at the top.
|
||||
*/
|
||||
export declare function intersectAtX(gradient: number, coefficient: number, x?: number, reflection?: number): Point;
|
||||
/**
|
||||
* Round each component of the vector.
|
||||
*/
|
||||
export declare function round(a: Point, decimals?: number): Point;
|
||||
/**
|
||||
* Check if the components of `a` and `b` are equal.
|
||||
*/
|
||||
export declare function equal(a: Point, b: Point): boolean;
|
||||
/**
|
||||
* Create a vector from an `x` and `y`.
|
||||
*/
|
||||
export declare function from(x: number, y: number): Point;
|
||||
/**
|
||||
* Create a vector from a widget event.
|
||||
*/
|
||||
export declare function from(event: {
|
||||
currentX: number;
|
||||
currentY: number;
|
||||
}): Point;
|
||||
/**
|
||||
* Create a vector from a html element's `offsetWidth` and `offsetHeight`.
|
||||
*/
|
||||
export declare function from(element: {
|
||||
offsetWidth: number;
|
||||
offsetHeight: number;
|
||||
}): Point;
|
||||
/**
|
||||
* Create a pair of vectors of the top left and bottom right of a bounding box.
|
||||
*/
|
||||
export declare function from(bbox: {
|
||||
x: number;
|
||||
y: number;
|
||||
width: number;
|
||||
height: number;
|
||||
}): [Point, Point];
|
||||
/**
|
||||
* Create a pair of vectors from a line or box containing a pair of coordinates.
|
||||
*/
|
||||
export declare function from(vec4: Bounds4): [Point, Point];
|
||||
/**
|
||||
* Apply the components of `b` to `a` and return `a`.
|
||||
*/
|
||||
export declare function apply(a: Partial<Point>, b: Point): Point;
|
||||
/**
|
||||
* Create a vector, defaulting the components to `0` if nullish.
|
||||
*/
|
||||
export declare function required(a?: Partial<Point>): Point;
|
||||
/**
|
||||
* Create a vector at the origin point (0,0).
|
||||
*/
|
||||
export declare function origin(): Point;
|
||||
62
node_modules/ag-charts-core/dist/types/src/utils/geometry/vector4.d.ts
generated
vendored
Executable file
62
node_modules/ag-charts-core/dist/types/src/utils/geometry/vector4.d.ts
generated
vendored
Executable file
@@ -0,0 +1,62 @@
|
||||
import type { Bounds4, Point } from '../../types/scene';
|
||||
/**
|
||||
* An interface for a vector with 4 components, considered to be a pair of vector2 coordinates. This can represent a
|
||||
* line with a start and end point, or two opposite corners of a box. There is no inherent ordering of the values
|
||||
* for each component, though positional functions such as `topCenter` will consider the min or max of each pair
|
||||
* of `x` and `y` components.
|
||||
*/
|
||||
/**
|
||||
* Get the vector2 at the start of a vector4.
|
||||
*/
|
||||
export declare function start(a: Bounds4): Point;
|
||||
/**
|
||||
* Get the vector2 at the end of a vector4.
|
||||
*/
|
||||
export declare function end(a: Bounds4): Point;
|
||||
/**
|
||||
* Get the vector2 at top center of a vector4.
|
||||
*/
|
||||
export declare function topCenter(a: Bounds4): Point;
|
||||
/**
|
||||
* Get the vector2 at center of a vector4.
|
||||
*/
|
||||
export declare function center(a: Bounds4): Point;
|
||||
/**
|
||||
* Get the vector2 at bottom center of a vector4.
|
||||
*/
|
||||
export declare function bottomCenter(a: Bounds4): Point;
|
||||
/**
|
||||
* Get the absolute width of a vector4.
|
||||
*/
|
||||
export declare function width(a: Bounds4): number;
|
||||
/**
|
||||
* Get the absolute height of a vector4.
|
||||
*/
|
||||
export declare function height(a: Bounds4): number;
|
||||
/**
|
||||
* Round each component of the vector4 to the nearest integer.
|
||||
*/
|
||||
export declare function round(a: Bounds4): Bounds4;
|
||||
/**
|
||||
* Clone a vector4.
|
||||
*/
|
||||
export declare function clone(a: Bounds4): Bounds4;
|
||||
export declare function collides(a: Bounds4, b: Bounds4): boolean;
|
||||
export declare function normalise(a: Bounds4): Bounds4;
|
||||
/**
|
||||
* Create a vector4 from an `x1`, `y1`, `x2` and `y2`.
|
||||
*/
|
||||
export declare function from(x1: number, y1: number, x2: number, y2: number): Bounds4;
|
||||
/**
|
||||
* Create a vector4 from a bounding box.
|
||||
*/
|
||||
export declare function from(bbox: {
|
||||
x: number;
|
||||
y: number;
|
||||
width: number;
|
||||
height: number;
|
||||
}): Bounds4;
|
||||
/**
|
||||
* Create a vector4 at the origin point (0,0).
|
||||
*/
|
||||
export declare function origin(): Bounds4;
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user