Skip to content

Commit

Permalink
Refactor: limit description length to 120 chars and re-style them (#7377
Browse files Browse the repository at this point in the history
)
  • Loading branch information
pauloiankoski authored Apr 29, 2024
1 parent 3a5fc46 commit 27cd65b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
11 changes: 5 additions & 6 deletions src/DonationForms/resources/styles/components/_amount.scss
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ $borderColor: #9A9A9A;

.givewp-fields-amount__level-container {
display: flex;
align-items: center;
align-items: start;
flex: 1;
gap: var(--givewp-spacing-4);
min-width: calc((100% - var(--givewp-spacing-2)) / 2);
Expand All @@ -145,17 +145,16 @@ $borderColor: #9A9A9A;
;

.givewp-fields-amount__level {
height: 100%;

&--description {
max-width: 144px;
}
}

.givewp-fields-amount__description {
margin-bottom: 0;
.givewp-fields-amount__level__description {
align-items: center;
color: var(--givewp-grey-700);
font-size: 1rem;
display: flex;
min-height: 100%;
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -226,6 +226,7 @@ const Inspector = ({attributes, setAttributes}) => {
toggleLabel={__('Enable amount description', 'give')}
toggleEnabled={descriptionsEnabled}
onHandleToggle={(value) => setAttributes({descriptionsEnabled: value})}
maxLabelLength={120}
/>
)}
</PanelBody>
Expand Down

0 comments on commit 27cd65b

Please sign in to comment.