Skip to content

Commit

Permalink
style(SearchSelect): 组件样式优化 #611 (#614)
Browse files Browse the repository at this point in the history
  • Loading branch information
nullptr-z committed Mar 4, 2022
1 parent 92a1bea commit f4325a0
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion packages/react-search-select/src/index.tsx
Expand Up @@ -233,7 +233,7 @@ export default function SearchSelect(props: SearchSelectProps) {
>
{isMultiple ? (
<div className={`${prefixCls}-inner`}>
<div style={{ display: 'flex', flexFlow: 'wrap' }}>
<div style={{ display: 'flex', flexFlow: 'wrap', width: '100%' }}>
{isMultiple &&
selectedValue.slice(0, maxTagCount).map((item, index) => {
return (
Expand Down
3 changes: 2 additions & 1 deletion packages/react-search-select/src/style/index.less
Expand Up @@ -5,7 +5,8 @@
input {
box-shadow: none;
padding: 0px;
height: 20px;
min-width: 50px;
height: 22px;
}

.w-input-inner {
Expand Down
4 changes: 2 additions & 2 deletions packages/react-search-tree/src/SearchTagInput.tsx
Expand Up @@ -134,7 +134,7 @@ function SearchTagInput<V extends SearchTagInputOption>(props: SearchTagInputPro
style={{ minWidth: 200, maxWidth: 'none', ...style }}
>
<div className={`${prefixCls}-inner`}>
<div style={{ display: 'flex', flexFlow: 'wrap' }}>
<div style={{ display: 'flex', flexFlow: 'wrap', width: '100%' }}>
{selectedOption.map((item, index) => {
return (
<Tag
Expand Down Expand Up @@ -164,7 +164,7 @@ function SearchTagInput<V extends SearchTagInputOption>(props: SearchTagInputPro
placeholder={selectedOption.length ? '' : placeholder}
/>
</div>
<span style={{ height: 25 }} className={`${prefixCls}-close-tag-contents`}>
<span style={{ height: 25, width: 14 }} className={`${prefixCls}-close-tag-contents`}>
{(selectIconType === 'close' || (selectIconType === 'loading' && loading)) && (
<Icon type={selectIconType} spin={loading && selectIconType === 'loading'} onClick={resetSelectedValue} />
)}
Expand Down
1 change: 1 addition & 0 deletions packages/react-search-tree/src/style/index.less
Expand Up @@ -6,6 +6,7 @@
box-shadow: none;
padding: 0px;
height: 20px;
min-width: 50px;
}

.w-input-inner {
Expand Down

0 comments on commit f4325a0

Please sign in to comment.