Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix checkbox layout #2182

Merged
merged 2 commits into from
Dec 7, 2023
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
4 changes: 2 additions & 2 deletions js/photos-main.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/photos-main.js.map

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions js/photos-public.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/photos-public.js.map

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions js/photos-src_views_FaceContent_vue.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/photos-src_views_FaceContent_vue.js.map

Large diffs are not rendered by default.

9 changes: 4 additions & 5 deletions src/components/File.vue
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,9 @@

<NcCheckboxRadioSwitch v-if="allowSelection"
class="selection-checkbox"
:aria-label="t('photos', 'Select image {imageName}', {imageName: file.basename})"
:checked="selected"
@update:checked="onToggle">
<span class="input-label">{{ t('photos', 'Select image {imageName}', {imageName: file.basename}) }}</span>
</NcCheckboxRadioSwitch>
@update:checked="onToggle" />

<Star v-if="file.favorite === 1"
v-once
Expand Down Expand Up @@ -335,14 +334,14 @@ export default {
width: fit-content;

// Make the checkbox background round on hover.
Copy link
Contributor

Choose a reason for hiding this comment

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

Right here, a nitpick is that now we want the background to always be present for accessibility reasons, no? So the comment could remove the hover part

:deep .checkbox-radio-switch__label {
:deep .checkbox-radio-switch__content {
padding: 10px;
box-sizing: border-box;
background: var(--color-primary-element-light);

// Add a background to the checkbox so we do not see the image through it.
&::after {
content: '';
background: var(--color-primary-element-light);
width: 16px;
height: 16px;
position: absolute;
Expand Down
Loading