Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,10 @@ jobs:
- uses: actions/checkout@v4

- name: Install pnpm
run: corepack enable pnpm
run: |
corepack enable
corepack prepare pnpm@10.0.0 --activate


- uses: actions/setup-node@v4
with:
Expand All @@ -35,7 +38,9 @@ jobs:
- uses: actions/checkout@v4

- name: Install pnpm
run: corepack enable pnpm
run: |
corepack enable
corepack prepare pnpm@10.0.0 --activate

- uses: actions/setup-node@v4
with:
Expand All @@ -60,7 +65,7 @@ jobs:
- uses: actions/checkout@v4

- name: Install pnpm
run: corepack enable pnpm
run: corepack disable && npm install -g pnpm@latest

- uses: actions/setup-node@v4
with:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/cypress.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@ jobs:
- uses: actions/checkout@v4

- name: Install pnpm
run: corepack enable pnpm
run: |
corepack enable
corepack prepare pnpm@10.0.0 --activate

- uses: actions/setup-node@v4
with:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/realease-tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@ jobs:
uses: actions/checkout@v4

- name: Install pnpm
run: corepack enable pnpm
run: |
corepack enable
corepack prepare pnpm@10.0.0 --activate

- uses: actions/setup-node@v4
with:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/sync-h5.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@ jobs:
- uses: actions/checkout@v4

- name: Install pnpm
run: corepack enable pnpm
run: |
corepack enable
corepack prepare pnpm@10.0.0 --activate

- uses: actions/setup-node@v4
with:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/sync-migrate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@ jobs:
- uses: actions/checkout@v4

- name: Install pnpm
run: corepack enable pnpm
run: |
corepack enable
corepack prepare pnpm@10.0.0 --activate

- uses: actions/setup-node@v4
with:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/sync-taro.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@ jobs:
- uses: actions/checkout@v4

- name: Install pnpm
run: corepack enable pnpm
run: |
corepack enable
corepack prepare pnpm@10.0.0 --activate

- uses: actions/setup-node@v4
with:
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ node_modules
.npmrc
/dist
/dist-demo
/dist-site
/libs
/jd/upload.js
# yarn.lock
Expand Down
2 changes: 1 addition & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
continue.</strong>
</noscript>
<div id="doc"></div>
<script type="module" src="/src/sites/doc/main.tsx"></script>
<script type="module" src="/src/sites/sites-react/doc/main.tsx"></script>
<script>
//分享配置
var shareOption = {
Expand Down
15 changes: 9 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
"changelog": "node ./scripts/generate-changelog.js",
"clone:jdharmony": "node ./scripts/harmony/clone-jdharmony.js",
"dev": "vite --open --force",
"dev:site:taro": "tsc && vite --force --config vite.config.site.taro.ts",
"dev:rtl": "VITE_RTL=rtl vite --open --force",
"dev:jrkf": "VITE_APP_PROJECT_ID=jrkf vite --open --force",
"dev:taro:rn:dark": "THEME=dark pnpm dev:taro:rn",
Expand All @@ -64,12 +65,14 @@
"build": "node ./scripts/replace-css-var.js && npm run checked && node scripts/build.mjs",
"build:taro": "node ./scripts/replace-css-var.js && npm run checked:taro && node scripts/build-taro.mjs",
"build:taro:jmapp": "npm run checked:taro && VITE_APP_PROJECT_ID=jmapp node scripts/build-taro.mjs",
"build:site": "npm run checked && vite build --config vite.config.site.ts",
"build:site:jmapp": "npm run checked && VITE_APP_PROJECT_ID=jmapp vite build",
"build:taro:site": "pnpm update:taro:entry && npm run checked:taro && npm run generate:file:taro:pages && pnpm --dir ./packages/nutui-taro-demo build:h5",
"build:jdtaro:site": "pnpm update:taro:entry && npm run checked:taro && npm run generate:file:taro:pages && JD=1 pnpm --dir ./packages/nutui-taro-demo build:h5",
"build:taro:site:jmapp": "npm run checked:taro && VITE_APP_PROJECT_ID=jmapp npm run generate:file:taro:pages && pnpm --dir ./packages/nutui-taro-demo build:h5",
"build:jstaro:site:jmapp": "npm run checked:taro && VITE_APP_PROJECT_ID=jmapp npm run generate:file:taro:pages && JD=1 pnpm --dir ./packages/nutui-taro-demo build:h5",
"build:demo": "npm run checked && vite build --config vite.config.demo.ts",
"build:demo:jmapp": "npm run checked && VITE_APP_PROJECT_ID=jmapp vite build",
"build:taro:demo": "pnpm update:taro:entry && npm run checked:taro && npm run generate:file:taro:pages && pnpm --dir ./packages/nutui-taro-demo build:h5",
"build:site": "vite build --config vite.config.site.ts",
"build:taro:site": "vite build --config vite.config.site.taro.ts",
"build:jdtaro:demo": "pnpm update:taro:entry && npm run checked:taro && npm run generate:file:taro:pages && JD=1 pnpm --dir ./packages/nutui-taro-demo build:h5",
"build:taro:demo:jmapp": "npm run checked:taro && VITE_APP_PROJECT_ID=jmapp npm run generate:file:taro:pages && pnpm --dir ./packages/nutui-taro-demo build:h5",
"build:jstaro:demo:jmapp": "npm run checked:taro && VITE_APP_PROJECT_ID=jmapp npm run generate:file:taro:pages && JD=1 pnpm --dir ./packages/nutui-taro-demo build:h5",
"generate:file": "node scripts/generate-nutui.js",
"generate:themes": "node scripts/generate-themes.js",
"generate:themes-dev": "node scripts/generate-themes-dev.js",
Expand Down
10 changes: 1 addition & 9 deletions src/packages/popup/doc.taro.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,14 +52,6 @@ import { Popup } from '@nutui/nutui-react-taro'

:::

<!-- ### 指定节点挂载

:::demo

<CodeBlock src='taro/demo6.tsx'></CodeBlock>

::: -->

### 多层堆叠

:::demo
Expand Down Expand Up @@ -110,7 +102,7 @@ import { Popup } from '@nutui/nutui-react-taro'
| description | 子标题/描述部分 | `ReactNode` | `-` |
| destroyOnClose | 组件不可见时,卸载内容 | `boolean` | `false` |
| round | 是否显示圆角 | `boolean` | `false` |
| portal | 指定节点挂载 | `HTMLElement` \| `(() => HTMLElement)` | null` | `null` |
| portal | 指定节点挂载 | ``HTMLElement` \| `(() => HTMLElement)` \| null`` | `null` |
| onClick | 点击弹框时触发 | `event: MouseEvent` | `-` |
| onCloseIconClick | 点击关闭图标时触发 | `event: MouseEvent` | `-` |
| onOpen | 打开弹框时触发 | `-` | `-` |
Expand Down
20 changes: 10 additions & 10 deletions src/packages/uploader/doc.en-US.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,25 +102,25 @@ import { Uploader } from '@nutui/nutui-react'
| deletable | Whether or not to show the delete button | `boolean` | `true` |
| method | The http method for the upload request | `string` | `post` | | previewType
| previewType | The built-in style of the uploaded list, two basic styles are supported picture, list | `string`
| capture | Picture [selection mode] (<https://developer.mozilla.org/zh-CN/docs/Web/HTML/Element/input#htmlattrdefcapture>"), directly bring up the camera | `string` | `false` | maxFileSize
| capture | Picture [selection mode](https://developer.mozilla.org/zh-CN/docs/Web/HTML/Element/input#htmlattrdefcapture), directly bring up the camera | `string` | `false` | maxFileSize
| maxFileSize | You can set the maximum file size (in bytes) for uploading | `number` \| `string` | `Number.MAX_VALUE` |
| maxCount | File upload count limit | `number` \| `string` | `1` |
| fit | Picture fill mode | `contain` \| `cover` \| `fill` \| `none` \| `scale-down` | `cover` |
| clearInput | If or not you want to clear the `input` content, set it to `true` to support selecting the same file to upload over and over again | `boolean` | `true` |
| accept | Allowed file types to be uploaded, [Details] ("<https://developer.mozilla.org/zh-CN/docs/Web/HTML/Element/Input/file#%E9%99%90%E5%88%B6%E5%85%81%E8%AE%> B8%E7%9A%84%E6%96%87%E4%BB%B6%E7%B1%BB%E5%9E%8B") | `string` | `*` |
| uploadIcon | uploadRegion <a href=#/zh-CN/icon>Icon Name</a> | `React.ReactNode` | `-` |
| accept | Allowed file types to be uploaded, [Details](https://developer.mozilla.org/zh-CN/docs/Web/HTML/Element/Input/file#%E9%99%90%E5%88%B6%E5%85%81%E8%AE%B8%E7%9A%84%E6%96%87%E4%BB%B6%E7%B1%BB%E5%9E%8B) | `string` | `*` |
| uploadIcon | uploadRegion <a href="#/zh-CN/icon">Icon Name</a> | `React.ReactNode` | `-` |
| deleteIcon | Delete the icon name of the region | `React.ReactNode` | `-` |
| uploadLabel | Text below the image in the upload area | `React.
| multiple | Whether to support file multi-selection |`boolean`|`false`|
| disabled | Whether to disable file uploading |`boolean`|`false`|
| beforeUpload | The beforeUpload function needs to return a`Promise`object |`(file: File[]) => Promise<File[] \| boolean>`|`-`|
| beforeDelete | Callback when deleting a file, does not remove it if the return value is false. Supports returning a`Promise`object, which is not removed when resolve(false) or reject |`(file: FileItem, files: FileItem[]) => boolean`|`-`|
| onOversize | Triggered when file size exceeds limit |`(file: File[]) => void`|`-`|
| beforeUpload | The beforeUpload function needs to return a`Promise`object |```(file: File[]) => Promise<File[] \| boolean>```|`-`|
| beforeDelete | Callback when deleting a file, does not remove it if the return value is false. Supports returning a`Promise`object, which is not removed when resolve(false) or reject |```(file: FileItem, files: FileItem[]) => boolean```|`-`|
| onOversize | Triggered when file size exceeds limit |```(file: File[]) => void```|`-`|
| onOverCount | Triggered when the number of files exceeds the limit |`(count: number) => void`|`-`|
| onChange | Triggered when the list of uploaded files changes |`(files: FileItem[]) => void`|`-`|
| onDelete | Triggered when clicked to delete a file |`(file: FileItem, files: FileItem[]) => void`|`-`|
| onFileItemClick | Triggered when a file is uploaded successfully |`(file: FileItem, index: number) => void`|`-`|
| onUploadQueueChange | Triggered when the image upload queue changes |`(tasks: FileItem[]) => void`|`-` |
| onChange | Triggered when the list of uploaded files changes |```(files: FileItem[]) => void```|`-`|
| onDelete | Triggered when clicked to delete a file |```(file: FileItem, files: FileItem[]) => void```|`-`|
| onFileItemClick | Triggered when a file is uploaded successfully |```(file: FileItem, index: number) => void```|`-`|
| onUploadQueueChange | Triggered when the image upload queue changes |```(tasks: FileItem[]) => void```|`-` |

> Note: accept, capture and multiple are the native attributes of the browser input tag, the support for these attributes varies among mobile models, so there may be some compatibility issues under different models and WebViews.

Expand Down
3 changes: 3 additions & 0 deletions src/sites/assets/images/icon-add.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 3 additions & 3 deletions src/sites/assets/styles/highlight.scss
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ code {
-webkit-font-smoothing: auto;
background-color: #fafafa;
border-radius: 16px;
}

code span {
font-family: $nutui-doc-code-font-family;
span {
font-family: $nutui-doc-code-font-family;
}
}

pre {
Expand Down
Loading