Skip to content

Commit

Permalink
Style for layout regular label
Browse files Browse the repository at this point in the history
  • Loading branch information
oandregal committed Nov 19, 2024
1 parent e819c8e commit c724251
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 8 deletions.
18 changes: 10 additions & 8 deletions packages/dataviews/src/dataforms-layouts/regular/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -105,13 +105,15 @@ export default function FormRegularField< Item >( {
}

return (
<fieldDefinition.Edit
data={ data }
field={ fieldDefinition }
onChange={ onChange }
hideLabelFromVision={
labelPosition === 'none' ? true : hideLabelFromVision
}
/>
<div className="dataforms-layouts-regular__field">
<fieldDefinition.Edit
data={ data }
field={ fieldDefinition }
onChange={ onChange }
hideLabelFromVision={
labelPosition === 'none' ? true : hideLabelFromVision
}
/>
</div>
);
}
6 changes: 6 additions & 0 deletions packages/dataviews/src/dataforms-layouts/regular/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@
align-items: flex-start !important;
}

.dataforms-layouts-regular__field .components-base-control__label {
font-size: inherit;
font-weight: normal;
text-transform: none;
}

.dataforms-layouts-regular__field-label {
width: 38%;
flex-shrink: 0;
Expand Down

0 comments on commit c724251

Please sign in to comment.