mirror of
https://github.com/ant-design/ant-design.git
synced 2025-06-07 17:44:35 +08:00
chore: merge master into feature
This commit is contained in:
commit
59ef0dc0a3
@ -16,5 +16,5 @@
|
||||
|
||||
html {
|
||||
scrollbar-width: thin;
|
||||
scrollbar-color: unset;
|
||||
scrollbar-color: #eaeaea transparent;
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
import React, { cloneElement, isValidElement } from 'react';
|
||||
import { BugOutlined } from '@ant-design/icons';
|
||||
import { Drawer, Flex, Grid, Popover, Tag, Timeline, Typography, Button } from 'antd';
|
||||
import { Button, Drawer, Flex, Grid, Popover, Tag, Timeline, Typography } from 'antd';
|
||||
import type { TimelineItemProps } from 'antd';
|
||||
import { createStyles } from 'antd-style';
|
||||
import semver from 'semver';
|
||||
@ -76,7 +76,7 @@ const useStyle = createStyles(({ token, css }) => ({
|
||||
position: 'relative',
|
||||
[`> ${token.antCls}-drawer-body`]: {
|
||||
scrollbarWidth: 'thin',
|
||||
scrollbarColor: 'unset',
|
||||
scrollbarGutter: 'stable',
|
||||
},
|
||||
},
|
||||
versionWrap: css`
|
||||
|
@ -15,7 +15,7 @@ const useStyle = createStyles(({ token, css }) => {
|
||||
background: ${colorBgContainer};
|
||||
&-scroll-container {
|
||||
scrollbar-width: thin;
|
||||
scrollbar-color: unset;
|
||||
scrollbar-gutter: stable;
|
||||
}
|
||||
}
|
||||
.dumi-default-source-code > pre,
|
||||
|
@ -169,7 +169,7 @@ const GlobalStyle: React.FC = () => {
|
||||
border-radius: ${token.borderRadius}px;
|
||||
> pre.prism-code {
|
||||
scrollbar-width: thin;
|
||||
scrollbar-color: unset;
|
||||
scrollbar-gutter: stable;
|
||||
padding: ${token.paddingSM}px ${token.paddingMD}px;
|
||||
font-size: ${token.fontSize}px;
|
||||
line-height: 2;
|
||||
@ -272,7 +272,7 @@ const GlobalStyle: React.FC = () => {
|
||||
.markdown .dumi-default-table {
|
||||
&-content {
|
||||
scrollbar-width: thin;
|
||||
scrollbar-color: unset;
|
||||
scrollbar-gutter: stable;
|
||||
}
|
||||
table {
|
||||
margin: 0;
|
||||
|
@ -10,7 +10,7 @@ export const useStyle = createStyles(({ token, css }) => {
|
||||
return {
|
||||
anchorToc: css`
|
||||
scrollbar-width: thin;
|
||||
scrollbar-color: unset;
|
||||
scrollbar-gutter: stable;
|
||||
${antCls}-anchor {
|
||||
${antCls}-anchor-link-title {
|
||||
font-size: ${token.fontSizeSM}px;
|
||||
|
@ -99,7 +99,7 @@ const useStyle = createStyles(({ token, css }) => {
|
||||
}
|
||||
& > section {
|
||||
scrollbar-width: thin;
|
||||
scrollbar-color: unset;
|
||||
scrollbar-gutter: stable;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -142,7 +142,7 @@ const useStyle = createStyles(({ token, css }) => {
|
||||
.rc-virtual-list {
|
||||
.rc-virtual-list-holder {
|
||||
scrollbar-width: thin;
|
||||
scrollbar-color: unset;
|
||||
scrollbar-gutter: stable;
|
||||
}
|
||||
}
|
||||
`,
|
||||
|
@ -91,18 +91,17 @@ const useStyle = createStyles(({ token, css }) => {
|
||||
`,
|
||||
mainMenu: css`
|
||||
z-index: 1;
|
||||
position: sticky;
|
||||
top: ${token.headerHeight + token.contentMarginTop}px;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
max-height: calc(100vh - ${token.headerHeight + token.contentMarginTop}px);
|
||||
overflow: hidden;
|
||||
scrollbar-width: thin;
|
||||
scrollbar-color: unset;
|
||||
|
||||
.ant-menu {
|
||||
padding: 0 4px;
|
||||
}
|
||||
position: sticky;
|
||||
top: ${token.headerHeight + token.contentMarginTop}px;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
max-height: calc(100vh - ${token.headerHeight + token.contentMarginTop}px);
|
||||
overflow: hidden;
|
||||
scrollbar-width: thin;
|
||||
scrollbar-gutter: stable;
|
||||
.ant-menu {
|
||||
padding: 0 4px;
|
||||
}
|
||||
|
||||
&:hover {
|
||||
overflow-y: auto;
|
||||
|
2
.github/workflows/issue-schedule.yml
vendored
2
.github/workflows/issue-schedule.yml
vendored
@ -69,7 +69,7 @@ jobs:
|
||||
|
||||
const actionTitle = process.env.actionTitle + `(${issueList.length})`;
|
||||
|
||||
const markdownList = `<h2>${actionTitle}</h2>\n\n`
|
||||
const markdownList = `## ${actionTitle}\n\n`
|
||||
+ issueList.map(issue => `- [${issue.title}](${issue.html_url}) ${fromNow(issue.created_at)}`).join('\n')
|
||||
+ `\n\n > 🫵🏻 快去帮忙处理吧,社区需要你的帮助!`;
|
||||
|
||||
|
@ -84,7 +84,7 @@ exports[`renders components/affix/demo/on-change.tsx correctly 1`] = `
|
||||
|
||||
exports[`renders components/affix/demo/target.tsx correctly 1`] = `
|
||||
<div
|
||||
style="width:100%;height:100px;overflow:auto;box-shadow:0 0 0 1px #1677ff;scrollbar-width:thin;scrollbar-color:unset"
|
||||
style="width:100%;height:100px;overflow:auto;box-shadow:0 0 0 1px #1677ff;scrollbar-width:thin;scrollbar-gutter:stable"
|
||||
>
|
||||
<div
|
||||
style="width:100%;height:1000px"
|
||||
|
@ -7,7 +7,7 @@ const containerStyle: React.CSSProperties = {
|
||||
overflow: 'auto',
|
||||
boxShadow: '0 0 0 1px #1677ff',
|
||||
scrollbarWidth: 'thin',
|
||||
scrollbarColor: 'unset',
|
||||
scrollbarGutter: 'stable',
|
||||
};
|
||||
|
||||
const style: React.CSSProperties = {
|
||||
|
@ -377,7 +377,7 @@ export const prepareToken: (token: Parameters<GenStyleFn<'Badge'>>[0]) => BadgeT
|
||||
|
||||
const badgeFontHeight = fontHeight;
|
||||
const badgeShadowSize = lineWidth;
|
||||
const badgeTextColor = token.colorBgContainer;
|
||||
const badgeTextColor = token.colorTextLightSolid;
|
||||
const badgeColor = token.colorError;
|
||||
const badgeColorHover = token.colorErrorHover;
|
||||
|
||||
|
@ -34,7 +34,7 @@ const genRibbonStyle: GenerateStyle<BadgeToken> = (token) => {
|
||||
backgroundColor: token.colorPrimary,
|
||||
borderRadius: token.borderRadiusSM,
|
||||
[`${ribbonPrefixCls}-text`]: {
|
||||
color: token.colorTextLightSolid,
|
||||
color: token.badgeTextColor,
|
||||
},
|
||||
[`${ribbonPrefixCls}-corner`]: {
|
||||
position: 'absolute',
|
||||
|
@ -136,21 +136,49 @@ const floatButtonGroupStyle: GenerateStyle<FloatButtonToken, CSSObject> = (token
|
||||
flexDirection: 'column',
|
||||
top: 'auto',
|
||||
bottom: calc(floatButtonSize).add(margin).equal(),
|
||||
'&::after': {
|
||||
content: '""',
|
||||
position: 'absolute',
|
||||
width: '100%',
|
||||
height: margin,
|
||||
bottom: calc(margin).mul(-1).equal(),
|
||||
},
|
||||
},
|
||||
[`${groupPrefixCls}-bottom > ${groupPrefixCls}-wrap`]: {
|
||||
flexDirection: 'column',
|
||||
top: calc(floatButtonSize).add(margin).equal(),
|
||||
bottom: 'auto',
|
||||
'&::after': {
|
||||
content: '""',
|
||||
position: 'absolute',
|
||||
width: '100%',
|
||||
height: margin,
|
||||
top: calc(margin).mul(-1).equal(),
|
||||
},
|
||||
},
|
||||
[`${groupPrefixCls}-right > ${groupPrefixCls}-wrap`]: {
|
||||
flexDirection: 'row',
|
||||
left: { _skip_check_: true, value: calc(floatButtonSize).add(margin).equal() },
|
||||
right: { _skip_check_: true, value: 'auto' },
|
||||
'&::after': {
|
||||
content: '""',
|
||||
position: 'absolute',
|
||||
width: margin,
|
||||
height: '100%',
|
||||
left: { _skip_check_: true, value: calc(margin).mul(-1).equal() },
|
||||
},
|
||||
},
|
||||
[`${groupPrefixCls}-left > ${groupPrefixCls}-wrap`]: {
|
||||
flexDirection: 'row',
|
||||
left: { _skip_check_: true, value: 'auto' },
|
||||
right: { _skip_check_: true, value: calc(floatButtonSize).add(margin).equal() },
|
||||
'&::after': {
|
||||
content: '""',
|
||||
position: 'absolute',
|
||||
width: margin,
|
||||
height: '100%',
|
||||
right: { _skip_check_: true, value: calc(margin).mul(-1).equal() },
|
||||
},
|
||||
},
|
||||
[`${groupPrefixCls}-circle`]: {
|
||||
gap: margin,
|
||||
|
@ -755,7 +755,7 @@ exports[`renders components/layout/demo/fixed-sider.tsx correctly 1`] = `
|
||||
>
|
||||
<aside
|
||||
class="ant-layout-sider ant-layout-sider-dark"
|
||||
style="overflow:auto;height:100vh;position:fixed;inset-inline-start:0;top:0;bottom:0;scrollbar-width:thin;scrollbar-color:unset;flex:0 0 200px;max-width:200px;min-width:200px;width:200px"
|
||||
style="overflow:auto;height:100vh;position:fixed;inset-inline-start:0;top:0;bottom:0;scrollbar-width:thin;scrollbar-gutter:stable;flex:0 0 200px;max-width:200px;min-width:200px;width:200px"
|
||||
>
|
||||
<div
|
||||
class="ant-layout-sider-children"
|
||||
|
@ -22,7 +22,7 @@ const siderStyle: React.CSSProperties = {
|
||||
top: 0,
|
||||
bottom: 0,
|
||||
scrollbarWidth: 'thin',
|
||||
scrollbarColor: 'unset',
|
||||
scrollbarGutter: 'stable',
|
||||
};
|
||||
|
||||
const items: MenuProps['items'] = [
|
||||
|
@ -74,7 +74,7 @@ const genSiderStyle: GenerateStyle<LayoutToken, CSSObject> = (token) => {
|
||||
overflow: 'hidden',
|
||||
},
|
||||
|
||||
[`${componentCls}-trigger`]: {
|
||||
'&-trigger': {
|
||||
position: 'absolute',
|
||||
top: headerHeight,
|
||||
insetInlineEnd: token.calc(zeroTriggerWidth).mul(-1).equal(),
|
||||
|
@ -11857,7 +11857,7 @@ exports[`renders components/table/demo/filter-search.tsx extend context correctl
|
||||
|
||||
exports[`renders components/table/demo/fixed-header.tsx extend context correctly 1`] = `
|
||||
<div
|
||||
class="ant-table-wrapper acss-6kbv1r"
|
||||
class="ant-table-wrapper acss-10ugdpo"
|
||||
>
|
||||
<div
|
||||
class="ant-spin-nested-loading"
|
||||
@ -13226,7 +13226,7 @@ exports[`renders components/table/demo/fixed-header.tsx extend context correctly
|
||||
|
||||
exports[`renders components/table/demo/grouping-columns.tsx extend context correctly 1`] = `
|
||||
<div
|
||||
class="ant-table-wrapper acss-6kbv1r"
|
||||
class="ant-table-wrapper acss-10ugdpo"
|
||||
>
|
||||
<div
|
||||
class="ant-spin-nested-loading"
|
||||
|
@ -9494,7 +9494,7 @@ exports[`renders components/table/demo/filter-search.tsx correctly 1`] = `
|
||||
|
||||
exports[`renders components/table/demo/fixed-columns.tsx correctly 1`] = `
|
||||
<div
|
||||
class="ant-table-wrapper acss-6kbv1r"
|
||||
class="ant-table-wrapper acss-10ugdpo"
|
||||
>
|
||||
<div
|
||||
class="ant-spin-nested-loading"
|
||||
@ -10205,7 +10205,7 @@ exports[`renders components/table/demo/fixed-columns.tsx correctly 1`] = `
|
||||
|
||||
exports[`renders components/table/demo/fixed-columns-header.tsx correctly 1`] = `
|
||||
<div
|
||||
class="ant-table-wrapper acss-6kbv1r"
|
||||
class="ant-table-wrapper acss-10ugdpo"
|
||||
>
|
||||
<div
|
||||
class="ant-spin-nested-loading"
|
||||
@ -12121,7 +12121,7 @@ exports[`renders components/table/demo/fixed-columns-header.tsx correctly 1`] =
|
||||
|
||||
exports[`renders components/table/demo/fixed-gapped-columns.tsx correctly 1`] = `
|
||||
<div
|
||||
class="ant-table-wrapper acss-6kbv1r"
|
||||
class="ant-table-wrapper acss-10ugdpo"
|
||||
>
|
||||
<div
|
||||
class="ant-spin-nested-loading"
|
||||
@ -12840,7 +12840,7 @@ exports[`renders components/table/demo/fixed-gapped-columns.tsx correctly 1`] =
|
||||
|
||||
exports[`renders components/table/demo/fixed-header.tsx correctly 1`] = `
|
||||
<div
|
||||
class="ant-table-wrapper acss-6kbv1r"
|
||||
class="ant-table-wrapper acss-10ugdpo"
|
||||
>
|
||||
<div
|
||||
class="ant-spin-nested-loading"
|
||||
@ -14104,7 +14104,7 @@ exports[`renders components/table/demo/fixed-header.tsx correctly 1`] = `
|
||||
|
||||
exports[`renders components/table/demo/grouping-columns.tsx correctly 1`] = `
|
||||
<div
|
||||
class="ant-table-wrapper acss-6kbv1r"
|
||||
class="ant-table-wrapper acss-10ugdpo"
|
||||
>
|
||||
<div
|
||||
class="ant-spin-nested-loading"
|
||||
@ -27873,7 +27873,7 @@ exports[`renders components/table/demo/summary.tsx correctly 1`] = `
|
||||
class="ant-flex ant-flex-align-stretch ant-flex-gap-small ant-flex-vertical"
|
||||
>
|
||||
<div
|
||||
class="ant-table-wrapper acss-6kbv1r"
|
||||
class="ant-table-wrapper acss-10ugdpo"
|
||||
>
|
||||
<div
|
||||
class="ant-spin-nested-loading"
|
||||
@ -28056,7 +28056,7 @@ exports[`renders components/table/demo/summary.tsx correctly 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="ant-table-wrapper acss-6kbv1r"
|
||||
class="ant-table-wrapper acss-10ugdpo"
|
||||
>
|
||||
<div
|
||||
class="ant-spin-nested-loading"
|
||||
|
@ -12,7 +12,8 @@ const useStyle = createStyles(({ css, token }) => {
|
||||
${antCls}-table-body,
|
||||
${antCls}-table-content {
|
||||
scrollbar-width: thin;
|
||||
scrollbar-color: unset;
|
||||
scrollbar-color: #eaeaea transparent;
|
||||
scrollbar-gutter: stable;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -12,7 +12,8 @@ const useStyle = createStyles(({ css, token }) => {
|
||||
${antCls}-table-body,
|
||||
${antCls}-table-content {
|
||||
scrollbar-width: thin;
|
||||
scrollbar-color: unset;
|
||||
scrollbar-color: #eaeaea transparent;
|
||||
scrollbar-gutter: stable;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -12,7 +12,8 @@ const useStyle = createStyles(({ css, token }) => {
|
||||
${antCls}-table-body,
|
||||
${antCls}-table-content {
|
||||
scrollbar-width: thin;
|
||||
scrollbar-color: unset;
|
||||
scrollbar-color: #eaeaea transparent;
|
||||
scrollbar-gutter: stable;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -12,7 +12,8 @@ const useStyle = createStyles(({ css, token }) => {
|
||||
${antCls}-table-body,
|
||||
${antCls}-table-content {
|
||||
scrollbar-width: thin;
|
||||
scrollbar-color: unset;
|
||||
scrollbar-color: #eaeaea transparent;
|
||||
scrollbar-gutter: stable;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -12,7 +12,8 @@ const useStyle = createStyles(({ css, token }) => {
|
||||
${antCls}-table-body,
|
||||
${antCls}-table-content {
|
||||
scrollbar-width: thin;
|
||||
scrollbar-color: unset;
|
||||
scrollbar-color: #eaeaea transparent;
|
||||
scrollbar-gutter: stable;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -12,7 +12,8 @@ const useStyle = createStyles(({ css, token }) => {
|
||||
${antCls}-table-body,
|
||||
${antCls}-table-content {
|
||||
scrollbar-width: thin;
|
||||
scrollbar-color: unset;
|
||||
scrollbar-color: #eaeaea transparent;
|
||||
scrollbar-gutter: stable;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -120,7 +120,7 @@ Do it step by step:
|
||||
```
|
||||
|
||||
2. Add the language support for [rc-picker](https://github.com/react-component/picker), for example [this](https://github.com/react-component/picker/blob/master/src/locale/en_US.ts).
|
||||
3. Add the language support for [rc-pagination](https://github.com/react-component/pagination), for example [this](https://github.com/react-component/pagination/blob/master/src/locale/en_US.js).
|
||||
3. Add the language support for [rc-pagination](https://github.com/react-component/pagination), for example [this](https://github.com/react-component/pagination/blob/master/src/locale/en_US.ts).
|
||||
4. Wait for `rc-picker` and `rc-pagination` to release the new version containing the above.
|
||||
5. Update the `rc-picker` and `rc-pagination` versions in `antd` and add the remaining other necessary content for the language. for example [Azerbaijani PR](https://github.com/ant-design/ant-design/pull/21387).
|
||||
6. Add a test case for the language in [index.test.tsx](https://github.com/ant-design/ant-design/blob/master/components/locale/__tests__/index.test.tsx).
|
||||
|
@ -119,7 +119,7 @@ return (
|
||||
```
|
||||
|
||||
2. 为 [rc-picker](https://github.com/react-component/picker) 添加对应语言,参考 [这个](https://github.com/react-component/picker/blob/master/src/locale/en_US.ts)。
|
||||
3. 为 [rc-pagination](https://github.com/react-component/pagination) 添加对应语言,参考 [这个](https://github.com/react-component/pagination/blob/master/src/locale/en_US.js)。
|
||||
3. 为 [rc-pagination](https://github.com/react-component/pagination) 添加对应语言,参考 [这个](https://github.com/react-component/pagination/blob/master/src/locale/en_US.ts)。
|
||||
4. 等待 `rc-picker` 和 `rc-pagination` 发布含上述内容的最低版本。
|
||||
5. 参考 [阿塞拜疆语的 PR](https://github.com/ant-design/ant-design/pull/21387) 向 `antd` 发起 PR,完善对应语言的其他内容和更新 `rc-picker` 和 `rc-pagination` 版本。
|
||||
6. 在 [index.test.tsx](https://github.com/ant-design/ant-design/blob/master/components/locale/__tests__/index.test.tsx) 添加该语言的测试用例。
|
||||
|
@ -120,7 +120,11 @@
|
||||
"classnames": "^2.5.1",
|
||||
"copy-to-clipboard": "^3.3.3",
|
||||
"dayjs": "^1.11.11",
|
||||
<<<<<<< HEAD
|
||||
"rc-cascader": "~3.29.0",
|
||||
=======
|
||||
"rc-cascader": "~3.28.2",
|
||||
>>>>>>> master
|
||||
"rc-checkbox": "~3.3.0",
|
||||
"rc-collapse": "~3.8.0",
|
||||
"rc-dialog": "~9.6.0",
|
||||
@ -237,7 +241,7 @@
|
||||
"eslint-plugin-compat": "^6.0.1",
|
||||
"eslint-plugin-jest": "^28.8.3",
|
||||
"eslint-plugin-jsx-a11y": "^6.10.0",
|
||||
"eslint-plugin-react-hooks": "^5.1.0-beta-26f2496093-20240514",
|
||||
"eslint-plugin-react-hooks": "^5.0.0",
|
||||
"eslint-plugin-react-refresh": "^0.4.12",
|
||||
"fast-glob": "^3.3.2",
|
||||
"fetch-jsonp": "^1.3.0",
|
||||
|
@ -25,7 +25,7 @@ export const generateCssinjs = ({ key, beforeRender, render }: GenCssinjsOptions
|
||||
Promise.all(
|
||||
styleFiles.map(async (file) => {
|
||||
const absPath = url.pathToFileURL(file).href;
|
||||
const pathArr = file.split('/');
|
||||
const pathArr = file.split(path.sep);
|
||||
const styleIndex = pathArr.lastIndexOf('style');
|
||||
const componentName = pathArr[styleIndex - 1];
|
||||
let useStyle: StyleFn = () => {};
|
||||
|
Loading…
Reference in New Issue
Block a user