Skip to content

Commit 78753ca

Browse files
committed
Initial commit
0 parents  commit 78753ca

File tree

1,083 files changed

+128151
-0
lines changed

Some content is hidden

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

1,083 files changed

+128151
-0
lines changed

.editorconfig

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
root = true
2+
3+
[*]
4+
charset = utf-8
5+
indent_style = space
6+
indent_size = 2
7+
end_of_line = lf
8+
insert_final_newline = true
9+
trim_trailing_whitespace = true

.eslintignore

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
packages/lark-vchart
2+
packages/block-vchart

.gitattributes

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# Don't allow people to merge changes to these generated files, because the result
2+
# may be invalid. You need to run "rush update" again.
3+
pnpm-lock.yaml merge=text
4+
shrinkwrap.yaml merge=binary
5+
npm-shrinkwrap.json merge=binary
6+
yarn.lock merge=binary
7+
8+
# Rush's JSON config files use JavaScript-style code comments. The rule below prevents pedantic
9+
# syntax highlighters such as GitHub's from highlighting these comments as errors. Your text editor
10+
# may also require a special configuration to allow comments in JSON.
11+
#
12+
# For more information, see this issue: https://github.com/microsoft/rushstack/issues/1088
13+
#
14+
*.json linguist-language=JSON-with-Comments

.gitignore

+89
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,89 @@
1+
# Logs
2+
*.log
3+
npm-debug.log*
4+
yarn-debug.log*
5+
yarn-error.log*
6+
7+
# Runtime data
8+
*.pid
9+
*.seed
10+
*.pid.lock
11+
12+
# Directory for instrumented libs generated by jscoverage/JSCover
13+
lib-cov
14+
15+
# Coverage directory used by tools like istanbul
16+
coverage
17+
18+
# nyc test coverage
19+
.nyc_output
20+
21+
# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
22+
.grunt
23+
24+
# Bower dependency directory (https://bower.io/)
25+
bower_components
26+
27+
# node-waf configuration
28+
.lock-wscript
29+
30+
# Compiled binary addons (https://nodejs.org/api/addons.html)
31+
build/Release
32+
output
33+
dist
34+
esm
35+
es
36+
cjs
37+
build
38+
build-es5
39+
*.zip
40+
41+
*.zip
42+
stats.html
43+
report.html
44+
45+
coverage/
46+
47+
*.local.ts
48+
49+
# Dependency directories
50+
node_modules/
51+
jspm_packages/
52+
53+
# Optional npm cache directory
54+
.npm
55+
56+
# Optional eslint cache
57+
.eslintcache
58+
59+
# Optional REPL history
60+
.node_repl_history
61+
62+
# Output of 'npm pack'
63+
*.tgz
64+
65+
# Yarn Integrity file
66+
.yarn-integrity
67+
68+
# dotenv environment variables file
69+
.env
70+
71+
# next.js build output
72+
.next
73+
74+
# OS X temporary files
75+
.DS_Store
76+
77+
# IntelliJ IDEA project files; if you want to commit IntelliJ settings, this recipe may be helpful:
78+
# https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
79+
.idea/
80+
*.iml
81+
82+
# Rush temporary files
83+
common/deploy/
84+
common/temp/
85+
common/autoinstallers/*/.npmrc
86+
**/.rush/temp/
87+
88+
# Heft temporary files
89+
.heft

.lintstagedrc

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"{packages,tools}/**/*.{ts,tsx}": ["eslint --color --fix --quiet", "prettier --write --ignore-unknown"]
3+
}

.prettierignore

+26
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# https://prettier.io/docs/en/ignore.html
2+
#-------------------------------------------------------------------------------------------------------------------
3+
# Keep this section in sync with .gitignore
4+
#-------------------------------------------------------------------------------------------------------------------
5+
6+
👋 (copy + paste your .gitignore file contents here) 👋
7+
8+
#-------------------------------------------------------------------------------------------------------------------
9+
# Prettier-specific overrides
10+
#-------------------------------------------------------------------------------------------------------------------
11+
12+
# Rush files
13+
common/changes/
14+
common/scripts/
15+
common/config/
16+
CHANGELOG.*
17+
18+
# Package manager files
19+
pnpm-lock.yaml
20+
yarn.lock
21+
package-lock.json
22+
shrinkwrap.json
23+
24+
# Build outputs
25+
dist
26+
lib

.prettierrc.js

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
// Documentation for this file: https://prettier.io/en/configuration.html
2+
module.exports = {
3+
"printWidth": 120,
4+
"tabWidth": 2,
5+
"useTabs": false,
6+
"semi": true,
7+
"singleQuote": true,
8+
"quoteProps": "as-needed",
9+
"trailingComma": "none",
10+
"bracketSpacing": true,
11+
"arrowParens": "avoid",
12+
"proseWrap": "preserve",
13+
"htmlWhitespaceSensitivity": "css",
14+
"endOfLine": "lf"
15+
};

.vscode/find-unused-exports.json

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"ignore": {}
3+
}

.vscode/launch.json

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
{
2+
"version": "0.1.0",
3+
"configurations": [
4+
{
5+
"name": "unit test",
6+
"type": "pwa-node",
7+
"request": "launch",
8+
"program": "${workspaceFolder}/node_modules/.bin/jest",
9+
"args": ["${file}"],
10+
"console": "integratedTerminal",
11+
"internalConsoleOptions": "neverOpen"
12+
}
13+
]
14+
}

.vscode/settings.json

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
{
2+
// Eslint
3+
"eslint.format.enable": true,
4+
"eslint.validate": ["typescript", "javascript", "javascriptreact", "typescriptreact"],
5+
// Formatter
6+
"javascript.format.enable": false,
7+
"typescript.format.enable": false,
8+
"[javascript]": {
9+
"editor.defaultFormatter": "esbenp.prettier-vscode"
10+
},
11+
"[typescript]": {
12+
"editor.defaultFormatter": "esbenp.prettier-vscode"
13+
},
14+
"[json]": {
15+
"editor.defaultFormatter": "esbenp.prettier-vscode"
16+
},
17+
// Editor
18+
"editor.defaultFormatter": "esbenp.prettier-vscode",
19+
"editor.codeActionsOnSave": ["source.fixAll.eslint"],
20+
"editor.formatOnSave": true,
21+
"editor.tabSize": 2,
22+
"editor.detectIndentation": false,
23+
// Typescript
24+
"typescript.preferences.importModuleSpecifier": "project-relative"
25+
}

.vscode/tasks.json

+22
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
{
2+
"version": "2.0.0",
3+
"tasks": [
4+
{
5+
"label": "web",
6+
"type": "shell",
7+
"isBackground": true,
8+
"command": "${workspaceFolder}/node_modules/.bin/tsc",
9+
"args": [
10+
"${file}",
11+
"--outFile",
12+
"${workspaceFolder}/packages/vchart/test/dist/index.js",
13+
"--strict",
14+
"--experimentalDecorators",
15+
"--sourceMap",
16+
"--skipLibCheck",
17+
"--watch"
18+
],
19+
"problemMatcher": ["$tsc-watch"]
20+
}
21+
]
22+
}

CODE_OF_CONDUCT.md

+47
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
# Contributor Covenant Code of Conduct
2+
3+
## Our Pledge
4+
5+
In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, religion, or sexual identity and orientation.
6+
7+
## Our Standards
8+
9+
Examples of behavior that contributes to creating a positive environment include:
10+
11+
- Using welcoming and inclusive language
12+
- Being respectful of differing viewpoints and experiences
13+
- Gracefully accepting constructive criticism
14+
- Focusing on what is best for the community
15+
- Showing empathy towards other community members
16+
17+
Examples of unacceptable behavior by participants include:
18+
19+
- The use of sexualized language or imagery and unwelcome sexual attention or advances
20+
- Trolling, insulting/derogatory comments, and personal or political attacks
21+
- Public or private harassment
22+
- Publishing others' private information, such as a physical or electronic address, without explicit permission
23+
- Other conduct which could reasonably be considered inappropriate in a professional setting
24+
25+
## Our Responsibilities
26+
27+
Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.
28+
29+
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.
30+
31+
## Scope
32+
33+
This Code of Conduct applies within all project spaces, and it also applies when an individual is representing the project or its community in public spaces. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers.
34+
35+
## Enforcement
36+
37+
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at https://github.com/VisActor. All complaints will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.
38+
39+
Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.
40+
41+
## Attribution
42+
43+
This Code of Conduct is adapted from the [Contributor Covenant](https://www.contributor-covenant.org), version 1.4,
44+
available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html
45+
46+
For answers to common questions about this code of conduct, see
47+
https://www.contributor-covenant.org/faq

CONTRIBUTING.md

+71
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
# Contributing
2+
3+
## Code of Conduct
4+
5+
We has adopted [the Contributor Covenant](CODE_OF_CONDUCT.md) as our Code of Conduct, and we expect project participants to adhere to it. Please read the full text so that you can understand what actions will and will not be tolerated.
6+
7+
## Open Development
8+
9+
All work on VChart happens directly on GitHub. Both core team members and external contributors send pull requests which go through the same review process.
10+
11+
## Semantic Versioning
12+
13+
VChart follows [semantic versioning](https://semver.org/). We release patch versions for critical bugfixes, minor versions for new features or non-essential changes, and major versions for any breaking changes. When we make breaking changes, we also introduce deprecation warnings in a minor version so that our users learn about the upcoming changes and migrate their code in advance.
14+
15+
Every significant change is documented in the changelog file.
16+
17+
## Release Schedule
18+
19+
todo
20+
21+
## Branch Organization
22+
23+
Submit all changes directly to the main branch. We don’t use separate branches for development or for upcoming releases. We do our best to keep main in good shape, with all tests passing.
24+
25+
Code that lands in main must be compatible with the latest stable release. It may contain additional features, but no breaking changes. We should be able to release a new minor version from the tip of main at any time.
26+
27+
## Bugs
28+
29+
We are using [GitHub Issues](todo) for our public bugs. We keep a close eye on this and try to make it clear when we have an internal fix in progress. Before filing a new task, try to make sure your problem doesn’t already exist.
30+
31+
We have already prepared issue templates for bug reports and feature requests. If you want to fire an issue, just enter the [New issue](todo) page and select either of them to get started. The best way to get your bug fixed is by using our issue template and provide reproduction steps with this [template](todo).
32+
33+
## Proposing a Change
34+
35+
If you intend to change the public API, or make any non-trivial changes to the implementation, we recommend filing an issue, or just enter the [New issue](todo) page and select either of them to get started.
36+
37+
If you’re only fixing a bug, it’s fine to submit a pull request right away but we still recommend to file an issue detailing what you’re fixing. This is helpful in case we don’t accept that specific fix but want to keep track of the issue.
38+
39+
## Your First Pull Request
40+
41+
Working on your first Pull Request? You can learn how from this free video series:[How to Contribute to an Open Source Project on GitHub](https://egghead.io/courses/how-to-contribute-to-an-open-source-project-on-github)
42+
43+
To help you get your feet wet and get you familiar with our contribution process, we have a list of [good first issues](todo) that contain bugs that have a relatively limited scope. This is a great place to get started.
44+
45+
If you decide to fix an issue, please be sure to check the comment thread in case somebody is already working on a fix. If nobody is working on it at the moment, please leave a comment stating that you intend to work on it so other people don’t accidentally duplicate your effort.
46+
47+
If somebody claims an issue but doesn’t follow up for more than two weeks, it’s fine to take it over but you should still leave a comment.
48+
49+
### Sending a Pull Request
50+
51+
The core team is monitoring for pull requests. We will review your pull request and either merge it, request changes to it, or close it with an explanation. We’ll do our best to provide updates and feedback throughout the process.
52+
53+
**Before submitting a pull request**, please make sure the following is done:
54+
55+
1. Fork the [repository](todo) and create your branch from `main`.
56+
2. (If rush has been install, just go to step 3) global install [@microsoft/rush](https://rushjs.io/pages/intro/get_started/)`npm i --global @microsoft/rush`.
57+
3. Run `rush update --full` in the repository root.
58+
4. If you’ve fixed a bug or added code that should be tested, add tests!
59+
5. Ensure the test suite passes (`rush test`). Tip: `rush test -- --watch TestName` is helpful in development.
60+
6. Make sure your code lints (`rush lint`). Tip: Lint runs automatically when you git commit (Use Git Hooks).
61+
7. Run `rush compile` for typecheck.
62+
63+
## Development Workflow
64+
65+
After cloning VChart, run `rush update --full` to fetch its dependencies. Then, you can run several commands:
66+
67+
1. `rush start` runs VChart test page locally.
68+
2. `rush eslint` checks the code style.
69+
3. `rush test` runs the complete test suite.
70+
4. `rush run -p <project_name> -s <script>` run the specified script for the specified project, eg. `rush run -p @visactor/vchart -s start`
71+
5. `rush prettier --dir <project_relative_path> --ext <file_type>` prettier the specified script for the specified project, eg. `rush prettier --dir packages/vchart --ext ts`

0 commit comments

Comments
 (0)