Skip to content

Commit

Permalink
fix(components): vertical label bg (#23)
Browse files Browse the repository at this point in the history
* fix(components): remove the colorErrorBg

* fix(components): fix label vertical label

* fix: update deps
  • Loading branch information
yee94 authored Jul 26, 2023
1 parent 458da30 commit 64e9c0a
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 8 deletions.
1 change: 1 addition & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
registry=https://registry.npmmirror.com/
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@
"@testing-library/jest-dom": "^5.0.0",
"@types/fs-extra": "^9.0.13",
"@types/jest": "^24.0.18",
"@types/moment": "^2.13.0",
"@types/node": "^18.11.9",
"@types/react": "^18.0.25",
"@types/react-dom": "^18.0.9",
Expand Down Expand Up @@ -95,4 +94,4 @@
"ts-node": "^10.9.1",
"typescript": "^4.1.5"
}
}
}
8 changes: 2 additions & 6 deletions packages/components/src/form-item/style/other.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ export const genOtherStyle: GenerateStyle = (token) => {

// Vertical Label: https://github.com/ant-design/ant-design/blob/master/components/form/style/index.ts#L391C1-L404C4
[`${componentCls}-label`]: {
lineHeight: 'unset',
minHeight: 'unset',
minHeight: lineHeight * fontSize + paddingXS,
lineHeight,
padding: `0 0 ${paddingXS}px`,

'&-content': {
Expand Down Expand Up @@ -183,7 +183,6 @@ export const genOtherStyle: GenerateStyle = (token) => {
[`${antCls}-select:not(${antCls}-select-disabled):not(${antCls}-select-customize-input)`]:
{
[`${antCls}-select-selector`]: {
backgroundColor: colorErrorBg,
borderColor: `${colorError} !important`,
},

Expand All @@ -195,7 +194,6 @@ export const genOtherStyle: GenerateStyle = (token) => {

[`${antCls}-input-number,
${antCls}-picker`]: {
backgroundColor: colorErrorBg,
borderColor: colorError,

[`&-focused,
Expand All @@ -204,13 +202,11 @@ export const genOtherStyle: GenerateStyle = (token) => {
},

[`&:not([disabled]):hover`]: {
backgroundColor: colorErrorBg,
borderColor: colorError,
},
},

[`${antCls}-cascader-picker:focus ${antCls}-cascader-input`]: {
backgroundColor: colorErrorBg,
...active(colorError),
},

Expand Down
5 changes: 5 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -10892,6 +10892,11 @@ modify-values@^1.0.0:
resolved "https://registry.npmmirror.com/modify-values/-/modify-values-1.0.1.tgz#b3939fa605546474e3e3e3c63d64bd43b4ee6022"
integrity sha512-xV2bxeN6F7oYjZWTe/YPAy6MN2M+sL4u/Rlm2AHCIVGfo2p1yGmBHQ6vHehl4bRTZBdHu3TSkWdYgkwpYzAGSw==

moment@^2.29.4:
version "2.29.4"
resolved "https://registry.npmmirror.com/moment/-/moment-2.29.4.tgz#3dbe052889fe7c1b2ed966fcb3a77328964ef108"
integrity sha512-5LC9SOxjSc2HF6vO2CyuTDNivEdoz2IvyJJGj6X8DJ0eFyfszE0QiEd+iXmBvUP3WHxSjFH/vIsA0EN00cgr8w==

move-concurrently@^1.0.1:
version "1.0.1"
resolved "https://registry.npmmirror.com/move-concurrently/-/move-concurrently-1.0.1.tgz#be2c005fda32e0b29af1f05d7c4b33214c701f92"
Expand Down

0 comments on commit 64e9c0a

Please sign in to comment.