Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions src/components/NcActionCheckbox/NcActionCheckbox.vue
Original file line number Diff line number Diff line change
Expand Up @@ -206,8 +206,7 @@ export default {

&::before {
margin-block: 0 !important;
// 16px is the width of the checkbox including the border
margin-inline: calc((var(--default-clickable-area) - 16px) / 2) !important;
margin-inline: calc((var(--default-clickable-area) - 14px) / 2) !important;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably, we should either add CSS variable for it, or change layout here to not use this number to avoid magic numbers.

P.S. On all supported versions on server it is 14px, not 16px

https://github.com/nextcloud/server/blob/stable28/core/css/inputs.scss#L414

}
}

Expand Down
5 changes: 2 additions & 3 deletions src/components/NcActionRadio/NcActionRadio.vue
Original file line number Diff line number Diff line change
Expand Up @@ -199,10 +199,9 @@ export default {
padding: 0 !important;
padding-right: $icon-margin !important;

// radio-width is 12px, border is 2
// (44 - 14 - 2) / 2 = 14
// (34 -14) / 2 = 10 same as ncactioncheckbox
&::before {
margin: 0 14px 0 !important;
margin: calc((var(--default-clickable-area) - 14px) / 2) !important;
}
}

Expand Down