Skip to content

Commit

Permalink
Merge branch 'main' into chore/remove-webpack.config.js
Browse files Browse the repository at this point in the history
  • Loading branch information
afc163 authored Nov 24, 2024
2 parents 8af5073 + f3e7883 commit 7a1044e
Show file tree
Hide file tree
Showing 6 changed files with 52 additions and 29 deletions.
32 changes: 16 additions & 16 deletions .github/workflows/site-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@ jobs:
env:
NODE_OPTIONS: --max_old_space_size=4096

# - name: build dist and bundle analyzer report
# run: bun run dist
# env:
# ANALYZER: 1
# NODE_OPTIONS: --max_old_space_size=4096
- name: build dist and bundle analyzer report
run: bun run compile
env:
ANALYZER: 1
NODE_OPTIONS: --max_old_space_size=4096

- name: Get version
id: publish-version
Expand All @@ -53,15 +53,15 @@ jobs:
source-repo: '[email protected]:ant-design/x.git'
destination-repo: '[email protected]:ant-design/antd-x.git'

# - name: Deploy to Surge (with TAG)
# run: |
# export DEPLOY_DOMAIN=ant-design-x-${{ steps.publish-version.outputs.VERSION }}.surge.sh
# cp report.html ./_site
# bunx surge --project ./_site --domain $DEPLOY_DOMAIN --token ${{ secrets.SURGE_TOKEN }}
- name: Deploy to Surge (with TAG)
run: |
export DEPLOY_DOMAIN=ant-design-x-${{ steps.publish-version.outputs.VERSION }}.surge.sh
cp report.html ./_site
bunx surge --project ./_site --domain $DEPLOY_DOMAIN --token ${{ secrets.SURGE_TOKEN }}
# - name: Create Commit Comment
# uses: peter-evans/commit-comment@v3
# with:
# body: |
# - Documentation site for this release: https://ant-design-x-${{ steps.publish-version.outputs.VERSION }}.surge.sh
# - Webpack bundle analyzer report page: https://ant-design-x-${{ steps.publish-version.outputs.VERSION }}.surge.sh/report.html
- name: Create Commit Comment
uses: peter-evans/commit-comment@v3
with:
body: |
- Documentation site for this release: https://ant-design-x-${{ steps.publish-version.outputs.VERSION }}.surge.sh
- Webpack bundle analyzer report page: https://ant-design-x-${{ steps.publish-version.outputs.VERSION }}.surge.sh/report.html
26 changes: 26 additions & 0 deletions .github/workflows/size-limit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: 📦 Size Limit

on:
pull_request:
types: [opened, synchronize]

permissions:
issues: write
contents: read

jobs:
size:
permissions:
contents: read
pull-requests: write
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v2
- name: size-limit
uses: ant-design/size-limit-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
package_manager: bun
build_script: compile
2 changes: 1 addition & 1 deletion README-zh_CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ pnpm add @ant-design/x

在浏览器中使用 `script``link` 标签直接引入文件,并使用全局变量 `antdx`

我们在 npm 发布包内的 dist 目录下提供了 `antdx.js``antdx.min.js``antdx.min.js.map`
我们在 npm 发布包内的 [dist](https://cdn.jsdelivr.net/npm/@ant-design/[email protected]/dist/) 目录下提供了 `antdx.js``antdx.min.js``antdx.min.js.map`

> **强烈不推荐使用已构建文件**,这样无法按需加载,而且难以获得底层依赖模块的 bug 快速修复支持。
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ pnpm add @ant-design/x

Add `script` and `link` tags in your browser and use the global variable `antd`.

We provide `antdx.js`, `antdx.min.js`, and `antdx.min.js.map` in the `dist` directory of the npm package.
We provide `antdx.js`, `antdx.min.js`, and `antdx.min.js.map` in the [dist](https://cdn.jsdelivr.net/npm/@ant-design/[email protected]/dist/) directory of the npm package.

## 🧩 Atomic Components

Expand Down
17 changes: 7 additions & 10 deletions components/bubble/loading.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,12 @@ interface LoadingProps {
prefixCls?: string;
}

const Loading: React.FC<Readonly<LoadingProps>> = (props) => {
const { prefixCls } = props;
return (
<span className={`${prefixCls}-dot`}>
<i className={`${prefixCls}-dot-item`} key={`item-${1}`} />
<i className={`${prefixCls}-dot-item`} key={`item-${2}`} />
<i className={`${prefixCls}-dot-item`} key={`item-${3}`} />
</span>
);
};
const Loading: React.FC<Readonly<LoadingProps>> = ({ prefixCls }) => (
<span className={`${prefixCls}-dot`}>
<i className={`${prefixCls}-dot-item`} key={`item-${1}`} />
<i className={`${prefixCls}-dot-item`} key={`item-${2}`} />
<i className={`${prefixCls}-dot-item`} key={`item-${3}`} />
</span>
);

export default Loading;
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@
},
"size-limit": [
{
"path": "./dist/antd-x.min.js",
"path": "./dist/antdx.min.js",
"limit": "350 KiB"
}
]
Expand Down

0 comments on commit 7a1044e

Please sign in to comment.