Skip to content

Commit e8613b9

Browse files
Merge commit '16d45746d0dc1f53bb39271a4550e79eac054550' as 'packages/apexcharts'
2 parents 4c9dc0e + 873e75f commit e8613b9

File tree

36,059 files changed

+219697
-5747953
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

36,059 files changed

+219697
-5747953
lines changed

.codeclimate.yml

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
checks:
2+
argument-count:
3+
config:
4+
threshold: 4
5+
complex-logic:
6+
config:
7+
threshold: 4
8+
file-lines:
9+
config:
10+
threshold: 700
11+
method-complexity:
12+
config:
13+
threshold: 20
14+
method-count:
15+
config:
16+
threshold: 20
17+
method-lines:
18+
config:
19+
threshold: 100
20+
nested-control-flow:
21+
config:
22+
threshold: 4
23+
return-statements:
24+
config:
25+
threshold: 4
26+
exclude_patterns:
27+
- 'config/'
28+
- 'db/'
29+
- 'dist/'
30+
- 'features/'
31+
- '**/node_modules/'
32+
- 'script/'
33+
- 'samples/'
34+
- '**/samples/'
35+
- '**/spec/'
36+
- '**/test/'
37+
- '**/tests/'
38+
- 'Tests/'
39+
- '**/vendor/'
40+
- '**/*_test.go'
41+
- '**/*.d.ts'
42+
- 'src/svgjs/'
43+
- 'src/modules/settings/Options.js'

.editorconfig

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
root = true
22

33
[*]
4-
end_of_line = lf
5-
insert_final_newline = true
6-
7-
[*.{js,json,yml}]
84
charset = utf-8
95
indent_style = space
106
indent_size = 2
7+
end_of_line = lf
8+
insert_final_newline = true
9+
trim_trailing_whitespace = true

.eslintignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
dist/
2+
assets/
3+
src/svgjs/
4+
node_modules/
5+
tests/coverage/

.eslintrc.js

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
module.exports = {
2+
root: true,
3+
parserOptions: {
4+
ecmaVersion: 2021,
5+
parser: 'babel-eslint',
6+
sourceType: 'module'
7+
},
8+
env: {
9+
browser: true,
10+
es6: true,
11+
node: true
12+
},
13+
extends: ['prettier'],
14+
plugins: ['promise'],
15+
globals: {
16+
Blob: true,
17+
Image: true,
18+
URL: true,
19+
Apex: true,
20+
ApexCharts: true,
21+
screen: true
22+
},
23+
overrides: [
24+
{
25+
files: ['tests/**/*.js'],
26+
globals: {
27+
describe: true,
28+
it: true,
29+
expect: true
30+
}
31+
}
32+
]
33+
}

.gitattributes

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
1-
/.yarn/** linguist-vendored
2-
/.yarn/releases/* binary
3-
/.yarn/plugins/**/* binary
4-
/.pnp.* binary linguist-generated
1+
* text eol=lf
2+
3+
# These files are binary and should be left untouched
4+
# (binary is a macro for -text -diff)
5+
*.png binary
6+
*.jpg binary
7+
*.jpeg binary
8+
*.gif binary
9+
*.ico binary

.github/FUNDING.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
github: [brianlagunas]

.github/ISSUE_TEMPLATE/bug-report.md

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
---
2+
name: Bug Report
3+
about: 🐞 Report a bug that you found
4+
labels: bug
5+
---
6+
7+
### Description
8+
9+
<!-- REQUIRED -->
10+
<!-- Issues reporting a bug, but lacking a Reproduction WILL BE CLOSED!
11+
Please ask questions in Discussions. Issues opened
12+
that are questions will be closed without comment. -->
13+
14+
### Steps to Reproduce
15+
16+
1.
17+
2.
18+
3.
19+
20+
### Expected Behavior
21+
22+
### Actual Behavior
23+
24+
### Screenshots
25+
26+
<!-- If the issue is a visual issue, please include screenshots showing the problem if possible -->
27+
28+
### Reproduction Link
29+
30+
<!-- REQUIRED -->
31+
<!--
32+
Modify this codepen https://codepen.io/apexcharts/pen/bxzgZJ to demonstrate the problem clearly, just fork it and paste the resulting codepen in your issue. Please make sure this is a minimal example, containing only the minimum necessary code to help us troubleshoot your problem. Issues/bug reports without reproducible example WILL BE CLOSED, so make sure you include one.
33+
34+
If you are using vue-apexcharts, and want to create a demo in Vue environment, use the CodeSandbox Vue template - https://codesandbox.io/s/pwwz8009n0
35+
If you are using react-apexcharts, and want to create a demo in React environment, use the CodeSandbox React template - https://codesandbox.io/s/6yoqonyo7r
36+
-->
37+

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
blank_issues_enabled: false
2+
contact_links:
3+
- name: Ask a Question
4+
url: https://github.com/apexcharts/apexcharts.js/discussions/new
5+
about: Please ask and answer questions for ApexCharts here.
6+
- name: Read the Docs
7+
url: https://apexcharts.com/docs/
8+
about: Be sure you've read the docs!
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
---
2+
name: Feature Request
3+
about: Suggest a feature you would like to have in ApexCharts
4+
labels: feature-request
5+
---
6+
7+
## Summary
8+
9+
Please provide a brief summary of your proposal. Two to three sentences is best here.
10+
11+
## API Changes
12+
13+
Include a list of all API changes, additions, subtractions as would be required by your proposal. These APIs should be considered placeholders, so the naming is not as important as getting the concepts correct. If possible you should include some "example" code of usage of your new API.
14+
15+
## Intended Use Case
16+
17+
Provide a detailed example of where your proposal would be used and for what purpose.
18+

.github/workflows/ci.yml

Lines changed: 107 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,107 @@
1+
# This workflow will do the following when a pull request is made against the main branch:
2+
# 1. Clone base repository (apexcharts/apexcharts.js), install npm packages, build samples, and then generate e2e snapshots
3+
# 2. Clone head repository (the repository with the code in the pull request), install npm packages, build samples, get snapshots generated from the base repository, run tests, and then generate an apexcharts build
4+
# Test coverage results, base repository snapshots, head repository snapshots and diffs, sample HTML, and the apexcharts build are all uploaded to the workflow artifacts
5+
# The diffs, build, and coverage results get uploaded even if the test fails for manual inspection and to make debugging easier
6+
7+
name: Node.js CI
8+
9+
on:
10+
pull_request:
11+
branches: [ main ]
12+
13+
jobs:
14+
build:
15+
name: Test & Build
16+
runs-on: ubuntu-latest
17+
18+
strategy:
19+
fail-fast: false
20+
matrix:
21+
node-version: [18.x, 20.x, 22.x]
22+
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
23+
24+
steps:
25+
- name: Create base repository artifacts folder
26+
run: mkdir -p ${{ runner.temp }}/artifacts/base-repository
27+
- name: Create head repository artifacts folder
28+
run: mkdir -p ${{ runner.temp }}/artifacts/head-repository
29+
30+
- name: Checkout base repository
31+
uses: actions/checkout@v4
32+
with:
33+
repository: ${{ github.event.pull_request.base.repo.full_name }}
34+
ref: ${{ github.event.pull_request.base.ref }}
35+
- name: Use Node.js ${{ matrix.node-version }}
36+
uses: actions/setup-node@v4
37+
with:
38+
node-version: ${{ matrix.node-version }}
39+
- name: Install base repository's packages
40+
run: npm ci
41+
- name: Generate base repository's samples
42+
run: npm run build:samples
43+
- name: Copy Base Repository Samples To Artifacts Folder
44+
run: cp -r samples/vanilla-js ${{ runner.temp }}/artifacts/base-repository/samples
45+
- name: Generate base repository's e2e snapshots
46+
run: npm run e2e:update
47+
- name: Copy Base Repository e2e Snapshots To Artifacts Folder
48+
run: cp -r tests/e2e/snapshots ${{ runner.temp }}/artifacts/base-repository/snapshots
49+
50+
- name: Checkout head repository
51+
uses: actions/checkout@v4
52+
- name: Install head repository's packages
53+
run: npm ci
54+
- name: Generate head repository's samples
55+
run: npm run build:samples
56+
- name: Copy Head Repository Samples To Artifacts Folder
57+
run: cp -r samples/vanilla-js ${{ runner.temp }}/artifacts/head-repository/samples
58+
- name: Delete snapshots folder
59+
run: rm -r tests/e2e/snapshots
60+
- name: Copy snapshots from base repository
61+
run: cp -r ${{ runner.temp }}/artifacts/base-repository/snapshots tests/e2e
62+
- name: Run tests
63+
run: npm run test:ci
64+
- name: Copy Head Repository Diffs To Artifacts Folder
65+
if: '!cancelled()'
66+
run: cp -r tests/e2e/diffs ${{ runner.temp }}/artifacts/head-repository/diffs
67+
- name: Build apexcharts
68+
if: '!cancelled()'
69+
run: npm run build --if-present
70+
- name: Copy Head Repository Build To Artifacts Folder
71+
if: '!cancelled()'
72+
run: cp -r dist ${{ runner.temp }}/artifacts/head-repository/build
73+
- name: Copy Head Repository Test Coverage To Artifacts Folder
74+
if: '!cancelled()'
75+
run: cp -r coverage ${{ runner.temp }}/artifacts/head-repository/coverage
76+
- name: Upload Artifacts
77+
if: '!cancelled()'
78+
uses: actions/upload-artifact@v4
79+
with:
80+
name: node${{ matrix.node-version }}${{ runner.os }}results
81+
path: ${{ runner.temp }}/artifacts
82+
83+
test-reproducibility:
84+
name: Test Reproducibility
85+
runs-on: ubuntu-latest
86+
87+
strategy:
88+
fail-fast: false
89+
matrix:
90+
node-version: [18.x, 20.x, 22.x]
91+
92+
steps:
93+
- name: Checkout repository
94+
uses: actions/checkout@v4
95+
- name: Setup Node ${{ matrix.node-version }}
96+
uses: actions/setup-node@v4
97+
with:
98+
node-version: ${{ matrix.node-version }}
99+
- name: Install packages
100+
run: npm ci
101+
- name: Build samples
102+
run: npm run build:samples
103+
- name: Generate snapshots
104+
run: npm run e2e:update
105+
- name: Run tests
106+
run: npm run test:ci
107+

0 commit comments

Comments
 (0)