diff --git a/client/src/app/account/account-settings/account-details/account-details.component.html b/client/src/app/account/account-settings/account-details/account-details.component.html index 593b87e29..c8e1e73b0 100644 --- a/client/src/app/account/account-settings/account-details/account-details.component.html +++ b/client/src/app/account/account-settings/account-details/account-details.component.html @@ -1,20 +1,23 @@
{{ error }}
- - -
- {{ formErrors['displayNSFW'] }} +
+ + + +
+ +
+ + +
-
- - diff --git a/client/src/app/account/account-settings/account-details/account-details.component.scss b/client/src/app/account/account-settings/account-details/account-details.component.scss index 1bdb19a38..4e8dfde1d 100644 --- a/client/src/app/account/account-settings/account-details/account-details.component.scss +++ b/client/src/app/account/account-settings/account-details/account-details.component.scss @@ -1,10 +1,8 @@ @import '_variables'; @import '_mixins'; -label { - font-size: 15px; - font-weight: $font-regular; - margin-left: 5px; +input[type=checkbox] { + @include peertube-checkbox(1px); } input[type=submit] { diff --git a/client/src/app/account/account-videos/account-videos.component.html b/client/src/app/account/account-videos/account-videos.component.html index 4f3a774bd..f73483039 100644 --- a/client/src/app/account/account-videos/account-videos.component.html +++ b/client/src/app/account/account-videos/account-videos.component.html @@ -7,7 +7,10 @@ (scrolledUp)="onNearOfTop()" >
- +
+ + +
diff --git a/client/src/app/account/account-videos/account-videos.component.scss b/client/src/app/account/account-videos/account-videos.component.scss index 0d478edd7..707bd66ad 100644 --- a/client/src/app/account/account-videos/account-videos.component.scss +++ b/client/src/app/account/account-videos/account-videos.component.scss @@ -46,11 +46,6 @@ min-height: 130px; padding-bottom: 20px; - input[type=checkbox] { - margin-right: 20px; - outline: 0; - } - &:first-child { margin-top: 47px; } @@ -60,6 +55,17 @@ border-bottom: 1px solid #C6C6C6; } + .checkbox-container { + display: flex; + align-items: center; + margin-right: 20px; + margin-left: 12px; + + input[type=checkbox] { + @include peertube-checkbox(2px); + } + } + my-video-thumbnail { margin-right: 10px; } diff --git a/client/src/app/videos/+video-edit/shared/video-edit.component.html b/client/src/app/videos/+video-edit/shared/video-edit.component.html index e728d8ea2..4f92b4908 100644 --- a/client/src/app/videos/+video-edit/shared/video-edit.component.html +++ b/client/src/app/videos/+video-edit/shared/video-edit.component.html @@ -95,6 +95,7 @@
+
diff --git a/client/src/app/videos/+video-edit/shared/video-edit.component.scss b/client/src/app/videos/+video-edit/shared/video-edit.component.scss index ba0ca1e21..4f8f031cf 100644 --- a/client/src/app/videos/+video-edit/shared/video-edit.component.scss +++ b/client/src/app/videos/+video-edit/shared/video-edit.component.scss @@ -21,7 +21,7 @@ display: block; &[type=checkbox] { - outline: 0; + @include peertube-checkbox(1px); } } diff --git a/client/src/sass/include/_mixins.scss b/client/src/sass/include/_mixins.scss index 4a709404d..a07bd5d28 100644 --- a/client/src/sass/include/_mixins.scss +++ b/client/src/sass/include/_mixins.scss @@ -148,3 +148,49 @@ cursor: default; } } + +@mixin peertube-checkbox ($border-width) { + display: none; + + & + label { + position: relative; + width: 18px; + height: 18px; + border: $border-width solid #000; + border-radius: 3px; + vertical-align: middle; + cursor: pointer; + + &:after { + content: ''; + position: absolute; + top: calc(2px - #{$border-width}); + left: 5px; + width: 5px; + height: 12px; + opacity: 0; + transform: rotate(45deg) scale(0); + border-right: 2px solid #fff; + border-bottom: 2px solid #fff; + } + } + + &:checked + label { + border-color: transparent; + background: $orange-color; + animation: jelly 0.6s ease; + + &:after { + opacity: 1; + transform: rotate(45deg) scale(1); + } + } + + & + label + label { + font-size: 15px; + font-weight: $font-regular; + margin-left: 5px; + cursor: pointer; + } +} +