diff --git a/.babelrc b/.babelrc deleted file mode 100644 index ed8668ada..000000000 --- a/.babelrc +++ /dev/null @@ -1,12 +0,0 @@ -{ - "presets": [ - [ - "@babel/preset-env", - { - "targets": { - "browsers": ["last 1 version", "> 1%", "IE 9"] - } - } - ] - ] -} diff --git a/.changeset/README.md b/.changeset/README.md deleted file mode 100644 index e5b6d8d6a..000000000 --- a/.changeset/README.md +++ /dev/null @@ -1,8 +0,0 @@ -# Changesets - -Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works -with multi-package repos, or single-package repos to help you version and publish your code. You can -find the full documentation for it [in our repository](https://github.com/changesets/changesets) - -We have a quick list of common questions to get you started engaging with this project in -[our documentation](https://github.com/changesets/changesets/blob/main/docs/common-questions.md) diff --git a/.changeset/config.json b/.changeset/config.json deleted file mode 100644 index d71842701..000000000 --- a/.changeset/config.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "$schema": "https://unpkg.com/@changesets/config@2.1.1/schema.json", - "changelog": "@changesets/cli/changelog", - "commit": false, - "fixed": [], - "linked": [], - "access": "restricted", - "baseBranch": "master", - "updateInternalDependencies": "patch", - "ignore": [] -} diff --git a/.editorconfig b/.editorconfig deleted file mode 100644 index 3331d7049..000000000 --- a/.editorconfig +++ /dev/null @@ -1,16 +0,0 @@ -# http://editorconfig.org -root = true - -[*] -indent_style = space -indent_size = 2 -end_of_line = lf -charset = utf-8 -trim_trailing_whitespace = true -insert_final_newline = true - -[*.md] -trim_trailing_whitespace = false - -[Makefile] -indent_style = tab \ No newline at end of file diff --git a/.eslintignore b/.eslintignore deleted file mode 100644 index ee900004a..000000000 --- a/.eslintignore +++ /dev/null @@ -1,10 +0,0 @@ -test/fixtures -dist -es -lib -config/wrapper.js -.docz -node_modules -gatsby-browser.js -*.ejs -*.min.js \ No newline at end of file diff --git a/.eslintrc.js b/.eslintrc.js deleted file mode 100644 index ba58caac0..000000000 --- a/.eslintrc.js +++ /dev/null @@ -1,30 +0,0 @@ -module.exports = { - env: { - browser: true, - es2021: true, - node: true, - jest: true, - }, - parser: '@typescript-eslint/parser', - parserOptions: { - ecmaVersion: 12, - sourceType: 'module', - }, - plugins: ['@typescript-eslint'], - rules: { - 'no-console': 'error', - noImplicitAny: 0, // 允许 any - 'no-unused-vars': ['warn', { varsIgnorePattern: '^_' }], - '@typescript-eslint/no-unused-vars': ['warn', { varsIgnorePattern: '^_' }], - }, - settings: { - 'import/parsers': { - '@typescript-eslint/parser': ['.ts', '.tsx'], - }, - 'import/resolver': { - typescript: { - alwaysTryTypes: true, - }, - }, - }, -}; diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md deleted file mode 100644 index 86700df45..000000000 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ /dev/null @@ -1,23 +0,0 @@ ---- -name: '报告Bug 🐛' -about: 报告 ant-design-charts 的 bug -title: '🐛[BUG]' -labels: '🐛 BUG' -assignees: '' ---- - -### 🐛 bug 描述 [详细地描述 bug,让大家都能理解] - -### 📷 复现步骤 [清晰描述复现步骤,让别人也能看到问题] - -### 🏞 期望结果 [描述你原本期望看到的结果] - -### 💻 复现代码 [提供可复现的代码,仓库,或线上示例] - -### © 版本信息 - -- ant-design-charts 版本: [e.g. 0.9.0] -- 浏览器环境 -- 开发环境 [e.g. mac OS] - -### 🚑 其他信息 [如截图等其他信息可以贴在这里] diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md deleted file mode 100644 index 4608c8350..000000000 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ /dev/null @@ -1,13 +0,0 @@ ---- -name: '功能需求 ✨' -about: 对 ant-design-charts 的需求或建议 -title: '👑 [需求]' -labels: '👑 Feature' -assignees: '' ---- - -### 🥰 需求描述 [详细地描述需求,让大家都能理解] - -### 🧐 解决方案 [如果你有解决方案,在这里清晰地阐述] - -### 🚑 其他信息 [如截图等其他信息可以贴在这里] diff --git a/.github/ISSUE_TEMPLATE/question.md b/.github/ISSUE_TEMPLATE/question.md deleted file mode 100644 index f7ae3bd65..000000000 --- a/.github/ISSUE_TEMPLATE/question.md +++ /dev/null @@ -1,13 +0,0 @@ ---- -name: '疑问或需要帮助 ❓' -about: 对 ant-design-charts 使用的疑问或需要帮助 -title: '🧐[问题]' -labels: '🧐 Question' -assignees: '' ---- - -### 🧐 问题描述 [详细地描述问题,让大家都能理解] - -### 💻 示例代码 [如果有必要,展示代码,线上示例,或仓库] - -### 🚑 其他信息 [如截图等其他信息可以贴在这里] diff --git a/.github/workflows/gh-pages.yml b/.github/workflows/gh-pages.yml deleted file mode 100644 index 72e5c5db6..000000000 --- a/.github/workflows/gh-pages.yml +++ /dev/null @@ -1,20 +0,0 @@ -name: github pages - -on: - push: - branches: - - master # default branch - -jobs: - deploy: - runs-on: ubuntu-18.04 - steps: - - uses: actions/checkout@v2 - - run: yarn - - run: yarn build - - run: yarn build:site - - name: Deploy - uses: peaceiris/actions-gh-pages@v3 - with: - github_token: ${{ secrets.GITHUB_TOKEN }} - publish_dir: ./packages/site/public diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml deleted file mode 100644 index 87adb6f9e..000000000 --- a/.github/workflows/lint.yml +++ /dev/null @@ -1,24 +0,0 @@ -name: Lint - -on: [push, pull_request] - -jobs: - lint: - runs-on: ubuntu-latest - strategy: - matrix: - node-version: [16.x] - steps: - - uses: actions/checkout@v3 - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v3 - with: - node-version: ${{ matrix.node-version }} - - name: installl pnpm - run: npm i pnpm@latest -g - - name: setup pnpm config - run: pnpm config set store-dir $PNPM_CACHE_FOLDER - - name: install dependencies - run: pnpm install - - name: lint - run: pnpm lint diff --git a/.github/workflows/preview.yml b/.github/workflows/preview.yml deleted file mode 100644 index 728c06bb9..000000000 --- a/.github/workflows/preview.yml +++ /dev/null @@ -1,26 +0,0 @@ -name: 🔂 Auto Inspection - -on: - pull_request: - branches: - - master - -jobs: - preview: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - name: Get branch name (pull request) - run: echo "BRANCH_NAME=$(echo ${GITHUB_HEAD_REF})" >> $GITHUB_ENV - - uses: lxfu1/surge-preview@2.0.3 - id: preview_step - with: - project_name: 'ant-design-charts' - dist_command: 'build' - project_branch: ${{ env.BRANCH_NAME }} - surge_token: ${{ secrets.SURGE_TOKEN }} - github_token: ${{ secrets.GITHUB_TOKEN }} - build: | - pnpm - - name: Get the preview url - run: echo "url => ${{ steps.preview_step.outputs.preview_url }}" diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml deleted file mode 100644 index 3c90b9c4b..000000000 --- a/.github/workflows/release.yml +++ /dev/null @@ -1,51 +0,0 @@ -name: Changesets -on: - push: - branches: - - master -env: - CI: true - PNPM_CACHE_FOLDER: .pnpm-store - -jobs: - version: - timeout-minutes: 15 - runs-on: ubuntu-latest - strategy: - matrix: - node-version: [16.x] - steps: - - name: checkout code repository - uses: actions/checkout@v3 - with: - fetch-depth: 0 - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v3 - with: - node-version: ${{ matrix.node-version }} - - name: install pnpm - run: npm i pnpm@latest -g - - name: Setup npmrc - run: | - cat << EOF > "$HOME/.npmrc" - email=${NPM_EMAIL} - //registry.npmjs.org/:_authToken=$NPM_TOKEN - EOF - env: - NPM_TOKEN: ${{ secrets.NPM_TOKEN }} - NPM_EMAIL: ${{ secrets.NPM_EMAIL }} - - name: setup pnpm config - run: pnpm config set store-dir $PNPM_CACHE_FOLDER - - name: install dependencies - run: pnpm install - - name: create publish versions - uses: changesets/action@v1 - with: - version: pnpm ci:version - commit: 'chore: release versions' - title: 'chore: release versions' - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - NPM_TOKEN: ${{ secrets.NPM_TOKEN }} - - name: publish to npm - run: pnpm run release \ No newline at end of file diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml deleted file mode 100644 index 6a7bb2caf..000000000 --- a/.github/workflows/test.yml +++ /dev/null @@ -1,36 +0,0 @@ -name: Test - -on: [push, pull_request] - -env: - CI: true - PNPM_CACHE_FOLDER: .pnpm-store - -jobs: - test: - runs-on: ubuntu-latest - timeout-minutes: 15 - strategy: - matrix: - node-version: [16.x] - steps: - - name: checkout code repository - uses: actions/checkout@v3 - with: - fetch-depth: 0 - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v3 - with: - node-version: ${{ matrix.node-version }} - - name: installl pnpm - run: npm i pnpm@latest -g - - name: setup pnpm config - run: pnpm config set store-dir $PNPM_CACHE_FOLDER - - name: install dependencies - run: pnpm install - - name: test - run: pnpm test - # - name: Coveralls - # uses: coverallsapp/github-action@master - # with: - # github-token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/v2-site.yml b/.github/workflows/v2-site.yml deleted file mode 100644 index ed01cc523..000000000 --- a/.github/workflows/v2-site.yml +++ /dev/null @@ -1,69 +0,0 @@ -name: V2 Site - -on: - pull_request: - branches: - - v2 # default branch -env: - CI: true - PNPM_STORE: .pnpm-store - -jobs: - deploy: - runs-on: ubuntu-latest - timeout-minutes: 15 - strategy: - matrix: - node-version: [16.x] - steps: - - name: checkout code repository - uses: actions/checkout@v3 - with: - fetch-depth: 0 - - name: Switch to site branch - run: git checkout -b site - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v3 - with: - node-version: ${{ matrix.node-version }} - - name: install pnpm - run: npm i pnpm@latest -g - - name: Setup npmrc - run: | - cat << EOF > "$HOME/.npmrc" - email=${NPM_EMAIL} - //registry.npmjs.org/:_authToken=$NPM_TOKEN - EOF - env: - NPM_TOKEN: ${{ secrets.NPM_TOKEN }} - NPM_EMAIL: ${{ secrets.NPM_EMAIL }} - - name: setup pnpm config - run: pnpm config set store-dir $PNPM_STORE - - name: install dependencies - run: pnpm install - - name: build site - run: | - pnpm run build:lib - pnpm run build:site - - name: copy and delete files - run: | - find . -maxdepth 1 -type f -exec rm -f {} \; - cp -r site/dist ./ - rm -rf site - rm -rf node_modules - rm -rf packages - rm -rf scripts - rm -rf public - rm -rf config - rm -rf template - rm -rf .changeset - rm -rf .github - rm -rf $PNPM_STORE - - name: commit changes - run: | - git config --local user.email "954055752@qq.com" - git config --local user.name "lxfu1" - git add . - git commit -m "chore: update site" - - name: push to site branch - run: git push origin site -f diff --git a/.gitignore b/.gitignore deleted file mode 100644 index b06fb9636..000000000 --- a/.gitignore +++ /dev/null @@ -1,37 +0,0 @@ -# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. - -# dependencies -node_modules -/npm-debug.log* -/yarn-error.log -/yarn.lock -/pnpm-lock.yaml -/package-lock.json -/pnpm-debug.log -/**/pnpm-debug.log -# production -dist -lib -es -logs -# misc -.DS_Store - -# umi -*.umi -.umi-production -.umi-test -/.env.local -.docz - -# dumi2 website builder -/**/.dumi/tmp -/**/.dumi/tmp-production - -#ide -.idea/ -.eslintcache -.vscode/** - -# temp -temp-gallery.md diff --git a/.npmrc b/.npmrc deleted file mode 100644 index 00e134fbe..000000000 --- a/.npmrc +++ /dev/null @@ -1,8 +0,0 @@ -auto-install-peers=true -strict-peer-dependencies=false -public-hoist-pattern[]=d3-* -public-hoist-pattern[]=@types/react -public-hoist-pattern[]=@types/react-dom -public-hoist-pattern[]=npm-run-all -public-hoist-pattern[]=rimraf -public-hoist-pattern[]=@antv/* \ No newline at end of file diff --git a/.prettierignore b/.prettierignore deleted file mode 100644 index 8af90c5d6..000000000 --- a/.prettierignore +++ /dev/null @@ -1,14 +0,0 @@ -**/*.svg -**/*.html -*.md -package.json -.umi -.umi-production -.umi-test -lib -es -dist -node_modules -*.ejs -gatsby-browser.js -*.min.js \ No newline at end of file diff --git a/.prettierrc.js b/.prettierrc.js deleted file mode 100644 index f30f82663..000000000 --- a/.prettierrc.js +++ /dev/null @@ -1,6 +0,0 @@ -const fabric = require('@umijs/fabric'); - -module.exports = { - ...fabric.prettier, - printWidth: 120, -}; diff --git a/.stylelintrc b/.stylelintrc deleted file mode 100644 index 3803d6081..000000000 --- a/.stylelintrc +++ /dev/null @@ -1,3 +0,0 @@ -{ - "extends": "@umijs/fabric/stylelint" -} diff --git a/CHANGELOG.md b/CHANGELOG.md deleted file mode 100644 index bdbc24379..000000000 --- a/CHANGELOG.md +++ /dev/null @@ -1,3 +0,0 @@ -## 2.0.0-alpah.0 - -`2023-08-31` diff --git a/CONTRIBUTING.zh-CN.md b/CONTRIBUTING.zh-CN.md deleted file mode 100644 index c997ea148..000000000 --- a/CONTRIBUTING.zh-CN.md +++ /dev/null @@ -1,153 +0,0 @@ -# 代码贡献规范 - -有任何疑问,欢迎提交 [issue](https://github.com/ant-design/ant-design-charts/issues) 或 [PR](https://github.com/ant-design/ant-design-charts/pulls)! - -## 开发 - -如果你有仓库的开发者权限,而且希望贡献代码,那么你可以创建分支修改代码提交 PR,AntV 开发团队会 review 代码合并到主干。 - -### 提交 Pull Request - -```bash -# clone 代码 -$ git clone -b v2 https://github.com/ant-design/ant-design-charts.git -$ cd ./ant-design-charts -# 依赖安装,由于项目使用了 pnpm 做多包管理,如果没有安装 pnpm,请先[安装pnpm](https://pnpm.io/installation#using-npm),并配置对应的 [store-dir](https://pnpm.io/configuring) -$ pnpm i -# 先创建开发分支开发,分支名应该有含义,避免使用 update、tmp 之类的 -$ git checkout -b branch-name -# 启动本地官网 -$ pnpm build:lib & pnpm start -# 监听要改动的包,eg plots -$ cd ./packages/plots -$ pnpm start -# 开发完成后跑下测试是否通过,必要时需要新增或修改测试用例 -$ pnpm test -# 测试通过后,提交代码,message 见下面的规范 -$ git add . # git add -u 删除文件 -$ git commit -m "fix(role): role.use must xxx" -$ git push origin branch-name -``` - -提交后就可以在 [Ant Design Charts](https://github.com/ant-design/ant-design-charts/pulls) 创建 Pull Request 了。 - -由于谁也无法保证过了多久之后还记得多少,为了后期回溯历史的方便,请在提交 MR 时确保提供了以下信息。 - -1. 需求点(一般关联 issue 或者注释都算) -2. 升级原因(不同于 issue,可以简要描述下为什么要处理) -3. 框架测试点(可以关联到测试文件,不用详细描述,关键点即可) -4. 关注点(针对用户而言,可以没有,一般是不兼容更新等,需要额外提示) - -### 测试 - -由于 Ant Design Charts 使用多包管理,除主包(packages/charts)外,各包之间相互独立,测试只需要保证当前包通过即可。 - -```ts -- packages - - charts - - plots - - util -``` - -### 代码风格 - -你的代码风格必须通过 eslint,你可以运行 `$ pnpm lint -r` 本地测试。 - -### Commit 提交规范 - -根据 [angular 规范](https://github.com/angular/angular.js/blob/master/CONTRIBUTING.md#commit-message-format)提交 commit,这样 history 看起来更加清晰,还可以自动生成 changelog。 - -```xml -(): - - - -