Skip to content

Commit

Permalink
chore: Adjust collapse arrow position align with first line (#27363)
Browse files Browse the repository at this point in the history
* fix: border style of Input.Search when allowClear (#27325)

* fix: border style of Input.Search when allowClear

* fix css

* update

* change name

* docs: 4.7.3 changelog (#27350)

* docs: 4.7.3 changelog

* docs: Patch 27325

* chore: improve useCombinedRefs (#27352)

* docs: 📝 update introduce

* chore: fix API table border

* chore: Adjust collapse arrow position align with first line

Co-authored-by: xrk <xrkffgg@gmail.com>
Co-authored-by: Tom Xu <ycxzhkx@gmail.com>
Co-authored-by: afc163 <afc163@gmail.com>
  • Loading branch information
4 people authored and 07akioni committed Nov 7, 2020
1 parent 7cafea5 commit 425c8ba
Show file tree
Hide file tree
Showing 18 changed files with 493 additions and 59 deletions.
19 changes: 19 additions & 0 deletions CHANGELOG.en-US.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,25 @@ timeline: true

---

## 4.7.3

`2020-10-24`

- Form
- 🐞 Fix Form warning for non-boolean attribute `virtual` when use ConfigProvider. [#27343](https://github.com/ant-design/ant-design/pull/27343)
- 🛠 Adjust Form.Item `initialValue` sync status align with Form level `initialValues`. [#27319](https://github.com/ant-design/ant-design/pull/27319)
- Typography
- 🛠 Improve Typography `ellipsis` title display. [#27328](https://github.com/ant-design/ant-design/pull/27328)
- 💄 Fix Editable Typography in Card title style problems. [#27221](https://github.com/ant-design/ant-design/pull/27221)
- Input
- 🐞 Fix Input.Search duplicated `className` when `allowClear` is `true`. [#27261](https://github.com/ant-design/ant-design/pull/27261)
- 🐞 Fix Input.Search border style when enable `allowClear`. [#27261](https://github.com/ant-design/ant-design/pull/27325)
- 🐞 Fix Upload.List preview image fit size issue. [#27312](https://github.com/ant-design/ant-design/pull/27312) [@JuniorTour](https://github.com/JuniorTour)
- 🐞 Fix Notification no wrap with long text. [#27285](https://github.com/ant-design/ant-design/pull/27285) [@littleee](https://github.com/littleee)
- 🐞 Fix Menu inside flexable container will not shrink properly. [#27253](https://github.com/ant-design/ant-design/pull/27253)
- 🌐 Fix en_US, en_GB and ga_IE gramma. [#27259](https://github.com/ant-design/ant-design/pull/27259) [@yasikovsky](https://github.com/yasikovsky)
- 🐞 Fix Tag with customize `closeIcon` breaks line issue. [#27226](https://github.com/ant-design/ant-design/pull/27226) [@handycode](https://github.com/handycode)

## 4.7.2

`2020-10-19`
Expand Down
19 changes: 19 additions & 0 deletions CHANGELOG.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,25 @@ timeline: true

---

## 4.7.3

`2020-10-24`

- Form
- 🐞 修复 Form 在 ConfigProvider 下会警告 `non-boolean attribute 'virtual'` 的问题。[#27343](https://github.com/ant-design/ant-design/pull/27343)
- 🛠 调整 Form.Item `initialValue` 的同步时机改由与 `initialValues` 相同。[#27319](https://github.com/ant-design/ant-design/pull/27319)
- Typography
- 🛠 优化 Typography 省略时的 `title` 提示,现在会在 `...` 上展现剩余文本。[#27328](https://github.com/ant-design/ant-design/pull/27328)
- 💄 修复 Typography 在 Card title 中编辑样式问题。[#27221](https://github.com/ant-design/ant-design/pull/27221)
- Input
- 🐞 修复 Input.Search 指定 `allowClear``className` 重复出现的问题。[#27261](https://github.com/ant-design/ant-design/pull/27261)
- 🐞 修复 修复 Input.Search 激活 `allowClear` 时边框样式异常的问题。[#27325](https://github.com/ant-design/ant-design/pull/27325)
- 🐞 修复 Upload.List 图片预览显示不全的问题。[#27312](https://github.com/ant-design/ant-design/pull/27312) [@JuniorTour](https://github.com/JuniorTour)
- 🐞 修复 Notification 长文本不换行的问题。[#27285](https://github.com/ant-design/ant-design/pull/27285) [@littleee](https://github.com/littleee)
- 🐞 修复 Menu 在 flex 容器内不会正常收缩省略的问题。[#27253](https://github.com/ant-design/ant-design/pull/27253)
- 🌐 修复 en_US、en_GB、ga_IE 国际化语法问题。[#27259](https://github.com/ant-design/ant-design/pull/27259) [@yasikovsky](https://github.com/yasikovsky)
- 🐞 修复 Tag 标签自定义关闭图标会导致换行的问题。[#27226](https://github.com/ant-design/ant-design/pull/27226) [@handycode](https://github.com/handycode)

## 4.7.2

`2020-10-19`
Expand Down
2 changes: 1 addition & 1 deletion components/_util/hooks/useCombinedRefs.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { fillRef } from '../ref';
function useCombinedRefs<T>(
...refs: Array<React.MutableRefObject<T> | ((instance: T) => void) | null>
) {
const targetRef = React.useRef();
const targetRef = React.useRef<T>();

React.useEffect(() => {
refs.forEach(ref => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1061,7 +1061,7 @@ exports[`renders ./components/auto-complete/demo/uncertain-category.md correctly
class="ant-select-selection-search"
>
<span
class="ant-input-group-wrapper ant-input-group-wrapper-lg ant-input-search ant-input-search-large ant-select-selection-search-input"
class="ant-input-group-wrapper ant-input-group-wrapper-lg ant-input-search ant-input-search-large ant-input-search-with-button ant-select-selection-search-input"
>
<span
class="ant-input-wrapper ant-input-group"
Expand Down
3 changes: 1 addition & 2 deletions components/collapse/style/index.less
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,10 @@
.iconfont-mixin();

position: absolute;
top: 50%;
top: ceil(@padding-sm + (@font-size-base * @line-height-base - @font-size-base) / 2);
left: @collapse-header-arrow-left;
display: inline-block;
font-size: @font-size-sm;
transform: translateY(-50%);

& svg {
transition: transform 0.24s;
Expand Down
3 changes: 2 additions & 1 deletion components/input/Search.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -109,12 +109,12 @@ const Search = React.forwardRef<Input, SearchProps>((props, ref) => {
className,
size: customizeSize,
suffix,
enterButton,
...restProps
} = props;

delete (restProps as any).onSearch;
delete (restProps as any).loading;
delete (restProps as any).enterButton;

const prefixCls = getPrefixCls('input-search', customizePrefixCls);
const inputPrefixCls = getPrefixCls('input', customizeInputPrefixCls);
Expand All @@ -125,6 +125,7 @@ const Search = React.forwardRef<Input, SearchProps>((props, ref) => {
{
[`${prefixCls}-rtl`]: direction === 'rtl',
[`${prefixCls}-${size}`]: !!size,
[`${prefixCls}-with-button`]: !!enterButton,
},
className,
);
Expand Down
14 changes: 7 additions & 7 deletions components/input/__tests__/__snapshots__/Search.test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ exports[`Input.Search should support addonAfter 1`] = `

exports[`Input.Search should support addonAfter 2`] = `
<span
class="ant-input-group-wrapper ant-input-search"
class="ant-input-group-wrapper ant-input-search ant-input-search-with-button"
>
<span
class="ant-input-wrapper ant-input-group"
Expand Down Expand Up @@ -202,13 +202,13 @@ exports[`Input.Search should support addonAfter and suffix for loading 1`] = `

exports[`Input.Search should support addonAfter and suffix for loading 2`] = `
<span
class="ant-input-group-wrapper ant-input-search"
class="ant-input-group-wrapper ant-input-search ant-input-search-with-button"
>
<span
class="ant-input-wrapper ant-input-group"
>
<span
class="ant-input-affix-wrapper ant-input-search"
class="ant-input-affix-wrapper ant-input-search ant-input-search-with-button"
>
<input
class="ant-input"
Expand Down Expand Up @@ -261,7 +261,7 @@ exports[`Input.Search should support addonAfter and suffix for loading 2`] = `

exports[`Input.Search should support custom Button 1`] = `
<span
class="ant-input-group-wrapper ant-input-search"
class="ant-input-group-wrapper ant-input-search ant-input-search-with-button"
>
<span
class="ant-input-wrapper ant-input-group"
Expand Down Expand Up @@ -289,7 +289,7 @@ exports[`Input.Search should support custom Button 1`] = `

exports[`Input.Search should support custom button 1`] = `
<span
class="ant-input-group-wrapper ant-input-search"
class="ant-input-group-wrapper ant-input-search ant-input-search-with-button"
>
<span
class="ant-input-wrapper ant-input-group"
Expand All @@ -314,7 +314,7 @@ exports[`Input.Search should support custom button 1`] = `

exports[`Input.Search should support invalid addonAfter 1`] = `
<span
class="ant-input-group-wrapper ant-input-search"
class="ant-input-group-wrapper ant-input-search ant-input-search-with-button"
>
<span
class="ant-input-wrapper ant-input-group"
Expand Down Expand Up @@ -460,7 +460,7 @@ exports[`Input.Search should support loading 1`] = `

exports[`Input.Search should support loading 2`] = `
<span
class="ant-input-group-wrapper ant-input-search"
class="ant-input-group-wrapper ant-input-search ant-input-search-with-button"
>
<span
class="ant-input-wrapper ant-input-group"
Expand Down

0 comments on commit 425c8ba

Please sign in to comment.