Skip to content

Commit

Permalink
fix(next): fix space item empty style (#3149)
Browse files Browse the repository at this point in the history
  • Loading branch information
janryWang authored May 26, 2022
1 parent 2b8e705 commit 18700a9
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 0 deletions.
10 changes: 10 additions & 0 deletions packages/next/docs/components/Space.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,16 @@ export default () => (
name="lastName"
x-decorator="FormItem"
x-component="Input"
x-visible="{{$values.firstName === '123'}}"
required
/>
<SchemaField.String
name="kk"
x-decorator="FormItem"
x-component="Input"
x-decorator-props={{
addonAfter: 'Unit',
}}
required
/>
</SchemaField.Void>
Expand Down
8 changes: 8 additions & 0 deletions packages/next/src/space/main.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
@import '~@alifd/next/lib/core/index-noreset.scss';
@import '~@alifd/next/lib/form/scss/variable.scss';

$space-prefix-cls: '#{$css-prefix}space';

.#{$space-prefix-cls}-item:empty {
display: none !important;
}
1 change: 1 addition & 0 deletions packages/next/src/space/style.ts
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
import '@alifd/next/lib/box/style'
import './main.scss'
1 change: 1 addition & 0 deletions packages/next/src/style.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,4 @@ import './form/main.scss'
import './preview-text/main.scss'
import './select-table/main.scss'
import './upload/main.scss'
import './space/main.scss'

0 comments on commit 18700a9

Please sign in to comment.