-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* chore: clean old workspace * chore: inject project tool * chore: ci * feat: all of components * docs: readme * docs: typo * chore: add changeset * chore: fix type err * chore: fix umd path * chore: eslint cli * chore: rename script * chore: umd filename * chore: trigger Preview * chore: export version * chore: add changeset * chore: ci jest * docs: quick start * refactor: dual axes plot
- Loading branch information
Showing
208 changed files
with
12,524 additions
and
362 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# 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) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"$schema": "https://unpkg.com/@changesets/[email protected]/schema.json", | ||
"changelog": ["@changesets/changelog-github", { "repo": "antvis/GPT-Vis" }], | ||
"commit": false, | ||
"fixed": [], | ||
"linked": [], | ||
"access": "restricted", | ||
"baseBranch": "main", | ||
"updateInternalDependencies": "patch", | ||
"ignore": [] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@antv/gpt-vis': patch | ||
--- | ||
|
||
feat: 20 + Visual components |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import { defineConfig } from 'dumi'; | ||
|
||
export default defineConfig({ | ||
outputPath: 'docs-dist', | ||
favicons: ['https://gw.alipayobjects.com/zos/antfincdn/FLrTNDvlna/antv.png'], | ||
themeConfig: { | ||
name: 'GPT-Vis', | ||
logo: 'https://gw.alipayobjects.com/zos/antfincdn/FLrTNDvlna/antv.png', | ||
footer: `Open-source MIT Licensed | Copyright © 2024 | ||
<br /> | ||
Powered by <a herf="https://antv.antgroup.com">Antv</a>`, | ||
socialLinks: { | ||
github: 'https://github.com/antvis/GPT-Vis', | ||
}, | ||
}, | ||
externals: { | ||
'mapbox-gl': 'window.mapboxgl', | ||
'maplibre-gl': 'window.maplibregl', | ||
}, | ||
theme: { | ||
'@c-primary': '#691eff', | ||
'@s-content-width': '100%', | ||
'@s-content-padding': '48px', | ||
'@s-sidebar-width': '300px', | ||
}, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,3 +11,6 @@ insert_final_newline = true | |
|
||
[*.md] | ||
trim_trailing_whitespace = false | ||
|
||
[Makefile] | ||
indent_style = tab |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
import { defineConfig } from 'father'; | ||
import { BundleAnalyzerPlugin } from 'webpack-bundle-analyzer'; | ||
|
||
export default defineConfig({ | ||
esm: { | ||
output: 'dist/esm', | ||
}, | ||
cjs: { | ||
output: 'dist/cjs', | ||
}, | ||
// https://github.com/umijs/father/blob/master/docs/config.md#umd | ||
umd: { | ||
name: 'GPTVis', | ||
output: { | ||
path: 'dist/umd', | ||
filename: 'index.min.js', | ||
}, | ||
platform: 'browser', | ||
targets: { | ||
chrome: 51, | ||
}, | ||
externals: { | ||
lodash: '_', | ||
'lodash-es': '_', | ||
react: 'React', | ||
'mapbox-gl': { | ||
root: 'mapboxgl', | ||
commonjs: 'mapbox-gl', | ||
commonjs2: 'mapbox-gl', | ||
amd: 'mapbox-gl', | ||
}, | ||
'maplibre-gl': { | ||
root: 'maplibregl', | ||
commonjs: 'maplibre-gl', | ||
commonjs2: 'maplibre-gl', | ||
amd: 'maplibre-gl', | ||
}, | ||
}, | ||
chainWebpack(memo) { | ||
// 关闭压缩方便调试,默认开启 | ||
// memo.optimization.minimize(false); | ||
|
||
memo | ||
.plugin('webpack-bundle-analyzer') | ||
.use(BundleAnalyzerPlugin, [{ analyzerMode: 'static', openAnalyzer: false }]); | ||
return memo; | ||
}, | ||
}, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,124 @@ | ||
title = "gitleaks config" | ||
[[rules]] | ||
description = "AWS Manager ID" | ||
regex = '''(A3T[A-Z0-9]|AKIA|AGPA|AIDA|AROA|AIPA|ANPA|ANVA|ASIA)[A-Z0-9]{16}''' | ||
tags = ["key", "AWS"] | ||
[[rules]] | ||
description = "AWS Secret Key" | ||
regex = '''(?i)aws(.{0,20})?(?-i)['\"][0-9a-zA-Z\/+]{40}['\"]''' | ||
tags = ["key", "AWS"] | ||
[[rules]] | ||
description = "AWS MWS key" | ||
regex = '''amzn\.mws\.[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}''' | ||
tags = ["key", "AWS", "MWS"] | ||
[[rules]] | ||
description = "Facebook Secret Key" | ||
regex = '''(?i)(facebook|fb)(.{0,20})?(?-i)['\"][0-9a-f]{32}['\"]''' | ||
tags = ["key", "Facebook"] | ||
[[rules]] | ||
description = "Facebook Client ID" | ||
regex = '''(?i)(facebook|fb)(.{0,20})?['\"][0-9]{13,17}['\"]''' | ||
tags = ["key", "Facebook"] | ||
[[rules]] | ||
description = "Twitter Secret Key" | ||
regex = '''(?i)twitter(.{0,20})?['\"][0-9a-z]{35,44}['\"]''' | ||
tags = ["key", "Twitter"] | ||
[[rules]] | ||
description = "Twitter Client ID" | ||
regex = '''(?i)twitter(.{0,20})?['\"][0-9a-z]{18,25}['\"]''' | ||
tags = ["client", "Twitter"] | ||
[[rules]] | ||
description = "Github" | ||
regex = '''(?i)github(.{0,20})?(?-i)['\"][0-9a-zA-Z]{35,40}['\"]''' | ||
tags = ["key", "Github"] | ||
[[rules]] | ||
description = "Github Token" | ||
regex = '''[0-9a-zA-Z]{35,40}''' | ||
tags = ["key", "Github Token"] | ||
[[rules]] | ||
description = "Alibaba" | ||
regex = '''(alibaba|antfin)-inc''' | ||
tags = ["key", "Alibaba"] | ||
[[rules]] | ||
description = "antfin" | ||
regex = '''(?i)antfin(.{0,20})?(?-i)['\"][0-9a-zA-Z]{35,40}['\"]''' | ||
tags = ["key", "Antfin"] | ||
[[rules]] | ||
description = "LinkedIn Client ID" | ||
regex = '''(?i)linkedin(.{0,20})?(?-i)['\"][0-9a-z]{12}['\"]''' | ||
tags = ["client", "LinkedIn"] | ||
[[rules]] | ||
description = "LinkedIn Secret Key" | ||
regex = '''(?i)linkedin(.{0,20})?['\"][0-9a-z]{16}['\"]''' | ||
tags = ["secret", "LinkedIn"] | ||
[[rules]] | ||
description = "Slack" | ||
regex = '''xox[baprs]-([0-9a-zA-Z]{10,48})?''' | ||
tags = ["key", "Slack"] | ||
[[rules]] | ||
description = "Asymmetric Private Key" | ||
regex = '''-----BEGIN ((EC|PGP|DSA|RSA|OPENSSH) )?PRIVATE KEY( BLOCK)?-----''' | ||
tags = ["key", "AsymmetricPrivateKey"] | ||
[[rules]] | ||
description = "Public Key" | ||
regex = '''ssh-rsa''' | ||
tags = ["keys", "public key"] | ||
[[rules]] | ||
description = "Gitlab Key" | ||
regex = '''privateToken|private-token''' | ||
tags = ["keys", "Gitlab"] | ||
[[rules]] | ||
description = "Generic Credential" | ||
regex = '''(?i)(api_key|apikey|secret)(.{0,20})?['|"][0-9a-zA-Z]{16,45}['|"]''' | ||
tags = ["key", "API", "generic"] | ||
[[rules]] | ||
description = "Google API key" | ||
regex = '''AIza[0-9A-Za-z\\-_]{35}''' | ||
tags = ["key", "Google"] | ||
[[rules]] | ||
description = "Heroku API key" | ||
regex = '''(?i)heroku(.{0,20})?['"][0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}['"]''' | ||
tags = ["key", "Heroku"] | ||
[[rules]] | ||
description = "MailChimp API key" | ||
regex = '''(?i)(mailchimp|mc)(.{0,20})?['"][0-9a-f]{32}-us[0-9]{1,2}['"]''' | ||
tags = ["key", "Mailchimp"] | ||
[[rules]] | ||
description = "Mailgun API key" | ||
regex = '''(?i)(mailgun|mg)(.{0,20})?['"][0-9a-z]{32}['"]''' | ||
tags = ["key", "Mailgun"] | ||
[[rules]] | ||
description = "PayPal Braintree access token" | ||
regex = '''access_token\$production\$[0-9a-z]{16}\$[0-9a-f]{32}''' | ||
tags = ["key", "Paypal"] | ||
[[rules]] | ||
description = "Picatic API key" | ||
regex = '''sk_live_[0-9a-z]{32}''' | ||
tags = ["key", "Picatic"] | ||
[[rules]] | ||
description = "SendGrid API Key" | ||
regex = '''SG\.[\w_]{16,32}\.[\w_]{16,64}''' | ||
tags = ["key", "SendGrid"] | ||
[[rules]] | ||
description = "Slack Webhook" | ||
regex = '''https://hooks.slack.com/services/T[a-zA-Z0-9_]{8}/B[a-zA-Z0-9_]{8}/[a-zA-Z0-9_]{24}''' | ||
tags = ["key", "slack"] | ||
[[rules]] | ||
description = "Stripe API key" | ||
regex = '''(?i)stripe(.{0,20})?['\"][sk|rk]_live_[0-9a-zA-Z]{24}''' | ||
tags = ["key", "Stripe"] | ||
[[rules]] | ||
description = "Square access token" | ||
regex = '''sq0atp-[0-9A-Za-z\-_]{22}''' | ||
tags = ["key", "square"] | ||
[[rules]] | ||
description = "Square OAuth secret" | ||
regex = '''sq0csp-[0-9A-Za-z\\-_]{43}''' | ||
tags = ["key", "square"] | ||
[[rules]] | ||
description = "Twilio API key" | ||
regex = '''(?i)twilio(.{0,20})?['\"][0-9a-f]{32}['\"]''' | ||
tags = ["key", "twilio"] | ||
[whitelist] | ||
description = "Whitelisted files" | ||
file = '''(^\.?gitleaks.toml$|(.*?)(jpg|gif|doc|pdf|bin)|package-lock\.json$)''' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
### PR includes | ||
|
||
<!-- Add completed items in this PR, and change [ ] to [x]. --> | ||
|
||
- [ ] fixed #0 | ||
- [ ] add / modify test cases | ||
- [ ] documents, demos | ||
|
||
### Screenshot | ||
|
||
| Before | After | | ||
| ------ | ----- | | ||
| ❌ | ✅ | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
name: 'Prepare Install' | ||
description: 'Prepare repository and install all dependencies' | ||
|
||
inputs: | ||
node-version: | ||
description: 'The node version to setup' | ||
required: true | ||
|
||
runs: | ||
using: 'composite' | ||
steps: | ||
- uses: pnpm/action-setup@v3 | ||
with: | ||
version: 9 | ||
|
||
- name: Use Node.js ${{ inputs.node-version }} | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: ${{ inputs.node-version }} | ||
# cache: 'pnpm' # pnpm-lock.yaml caching dependencies to speed up workflows | ||
|
||
- name: Install dependencies | ||
shell: bash | ||
run: pnpm install |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# for .github/workflows/release-label.yml | ||
# These labels can be used in conjunction GitHub's [automatically generated release notes](https://docs.github.com/en/repositories/releasing-projects-on-github/automatically-generated-release-notes) | ||
|
||
changelog: | ||
exclude: | ||
labels: | ||
- ignore-for-release | ||
- pr(chore) | ||
categories: | ||
- title: 🎉 New Features | ||
labels: | ||
- pr(feature) | ||
- title: 📖 Documentation Changes | ||
labels: | ||
- pr(documentation) | ||
- title: 🐛 Bug Fixes | ||
labels: | ||
- pr(bugfix) | ||
- title: 🛠 Breaking Changes | ||
labels: | ||
- pr(breaking) | ||
- title: Other Changes | ||
labels: | ||
- '*' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
name: CI | ||
|
||
on: | ||
push: | ||
branches: [master] | ||
paths: | ||
- 'src/**' | ||
- '__tests__/**' | ||
pull_request: | ||
branches: | ||
- '**' | ||
paths: | ||
- 'src/**' | ||
- '__tests__/**' | ||
|
||
permissions: | ||
contents: read # to fetch code (actions/checkout) | ||
|
||
concurrency: | ||
group: '${{ github.workflow }} - ${{ github.head_ref || github.ref }}' | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
lint: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
node-version: [18.x] | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Install dependencies | ||
uses: ./.github/actions/prepare-install | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
- name: Check | ||
run: | | ||
pnpm check-deps | ||
pnpm check-format | ||
- name: Lint | ||
run: pnpm lint:ts | ||
|
||
# unit-test: | ||
# runs-on: ubuntu-latest | ||
# strategy: | ||
# matrix: | ||
# node-version: [18.x] | ||
# steps: | ||
# - uses: actions/checkout@v4 | ||
# - name: Install dependencies | ||
# uses: ./.github/actions/prepare-install | ||
# with: | ||
# node-version: ${{ matrix.node-version }} | ||
# - name: Unit Test | ||
# run: pnpm test:unit | ||
|
||
size-test: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
node-version: [18.x] | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Install dependencies | ||
uses: ./.github/actions/prepare-install | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
- name: Szie Test With Build | ||
run: pnpm test:size |
Oops, something went wrong.