hide RSS for comments, normalize video-channel edit with account edit
authorRigel Kent <sendmemail@rigelk.eu>
Wed, 11 Mar 2020 23:45:45 +0000 (00:45 +0100)
committerRigel Kent <sendmemail@rigelk.eu>
Wed, 11 Mar 2020 23:46:48 +0000 (00:46 +0100)
client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.ts
client/src/app/+my-account/my-account-settings/my-account-settings.component.html
client/src/app/+my-account/my-account-video-channels/my-account-video-channel-edit.component.html
client/src/app/+my-account/my-account-video-channels/my-account-video-channel-edit.component.scss
client/src/app/menu/menu.component.html
client/src/app/videos/+video-watch/comment/video-comments.component.scss

index c3eac68bbf419474aa73826577d49da65e021b6d..d81859d5c34eeb5a6860ec13fd905ed9d0c879ad 100644 (file)
@@ -18,7 +18,7 @@ import { NgbTabset } from '@ng-bootstrap/ng-bootstrap'
   styleUrls: [ './edit-custom-config.component.scss' ]
 })
 export class EditCustomConfigComponent extends FormReactive implements OnInit, AfterViewChecked {
-  @ViewChild('tabs') private tabs: NgbTabset
+  @ViewChild('tabs') tabs: NgbTabset
 
   initDone = false
   customConfig: CustomConfig
index 87296bc19da70645b8b3b7dfc2027642de200acf..ddcde828c6d8d09910661cb0d72e45514164ea6e 100644 (file)
@@ -24,6 +24,7 @@
 
 <div class="form-row mt-5"> <!-- video settings grid -->
   <div class="form-group col-12 col-lg-4 col-xl-3">
+    <div class="anchor" id="video-settings"></div> <!-- video settings anchor -->
     <div i18n class="account-title">VIDEO SETTINGS</div>
   </div>
 
index f87df87dfcd747b7ee234eeaa45a553d10134965..cc20674c9af554ce584752023d8d47dff7e728ec 100644 (file)
@@ -1,8 +1,3 @@
-<my-actor-avatar-info
-  *ngIf="isCreation() === false && videoChannelToUpdate"
-  [actor]="videoChannelToUpdate" (avatarChange)="onAvatarChange($event)"
-></my-actor-avatar-info>
-
 <div i18n class="form-sub-title" *ngIf="isCreation() === true">Create a video channel</div>
 
 <div *ngIf="error" class="alert alert-danger">{{ error }}</div>
     </div>
   </div>
 
-  <div class="form-group">
-    <label i18n for="display-name">Display name</label>
-    <input
-      type="text" id="display-name"
-      formControlName="display-name" [ngClass]="{ 'input-error': formErrors['display-name'] }"
-    >
-    <div *ngIf="formErrors['display-name']" class="form-error">
-      {{ formErrors['display-name'] }}
+  <div class="form-row"> <!-- channel grid -->
+    <div class="form-group col-12 col-lg-4 col-xl-3">
+      <div i18n class="video-channel-title">CHANNEL</div>
     </div>
-  </div>
 
-  <div class="form-group">
-    <label i18n for="description">Description</label>
-    <textarea
-      id="description" formControlName="description"
-      [ngClass]="{ 'input-error': formErrors['description'] }"
-    ></textarea>
-    <div *ngIf="formErrors.description" class="form-error">
-      {{ formErrors.description }}
-    </div>
-  </div>
+    <div class="form-group form-group-right col-12 col-lg-8 col-xl-9">
+
+      <my-actor-avatar-info
+        *ngIf="isCreation() === false && videoChannelToUpdate"
+        [actor]="videoChannelToUpdate" (avatarChange)="onAvatarChange($event)"
+      ></my-actor-avatar-info>
+
+      <div class="form-group">
+        <label i18n for="display-name">Display name</label>
+        <input
+          type="text" id="display-name"
+          formControlName="display-name" [ngClass]="{ 'input-error': formErrors['display-name'] }"
+        >
+        <div *ngIf="formErrors['display-name']" class="form-error">
+          {{ formErrors['display-name'] }}
+        </div>
+      </div>
+    
+      <div class="form-group">
+        <label i18n for="description">Description</label>
+        <textarea
+          id="description" formControlName="description"
+          [ngClass]="{ 'input-error': formErrors['description'] }"
+        ></textarea>
+        <div *ngIf="formErrors.description" class="form-error">
+          {{ formErrors.description }}
+        </div>
+      </div>
+    
+      <div class="form-group">
+        <label for="support">Support</label>
+        <my-help
+          helpType="markdownEnhanced" i18n-preHtml preHtml="Short text to tell people how they can support your channel (membership platform...).<br /><br />
+    When you will upload a video in this channel, the video support field will be automatically filled by this text."
+        ></my-help>
+        <my-markdown-textarea
+            id="support" formControlName="support" textareaWidth="500px" [previewColumn]="true" markdownType="enhanced"
+            [classes]="{ 'input-error': formErrors['support'] }"
+        ></my-markdown-textarea>
+        <div *ngIf="formErrors.support" class="form-error">
+          {{ formErrors.support }}
+        </div>
+      </div>
+    
+      <div class="form-group" *ngIf="isBulkUpdateVideosDisplayed()">
+        <my-peertube-checkbox
+          inputName="bulkVideosSupportUpdate" formControlName="bulkVideosSupportUpdate"
+          i18n-labelText labelText="Overwrite support field of all videos of this channel"
+        ></my-peertube-checkbox>
+      </div>
 
-  <div class="form-group">
-    <label for="support">Support</label>
-    <my-help
-      helpType="markdownEnhanced" i18n-preHtml preHtml="Short text to tell people how they can support your channel (membership platform...).<br /><br />
-When you will upload a video in this channel, the video support field will be automatically filled by this text."
-    ></my-help>
-    <my-markdown-textarea
-        id="support" formControlName="support" textareaWidth="500px" [previewColumn]="true" markdownType="enhanced"
-        [classes]="{ 'input-error': formErrors['support'] }"
-    ></my-markdown-textarea>
-    <div *ngIf="formErrors.support" class="form-error">
-      {{ formErrors.support }}
     </div>
   </div>
 
-  <div class="form-group" *ngIf="isBulkUpdateVideosDisplayed()">
-    <my-peertube-checkbox
-      inputName="bulkVideosSupportUpdate" formControlName="bulkVideosSupportUpdate"
-      i18n-labelText labelText="Overwrite support field of all videos of this channel"
-    ></my-peertube-checkbox>
+  <div class="form-row"> <!-- submit placement block -->
+    <div class="col-md-7 col-xl-5"></div>
+    <div class="col-md-5 col-xl-5 d-inline-flex">
+      <input type="submit" value="{{ getFormButtonTitle() }}" [disabled]="!form.valid">
+    </div>
   </div>
-
-  <input type="submit" value="{{ getFormButtonTitle() }}" [disabled]="!form.valid">
 </form>
index d35e0ed64ecd2a78b9c22a9a6d4a3ce803160cf8..fa6b18b37cb9d582d4923c3961180cbdebf2769e 100644 (file)
@@ -1,6 +1,10 @@
 @import '_variables';
 @import '_mixins';
 
+.video-channel-title {
+  @include settings-big-title;
+}
+
 .form-sub-title {
   margin-bottom: 20px;
 }
@@ -18,28 +22,44 @@ my-actor-avatar-info {
   height: 30px;
 }
 
-input[type=text] {
-  @include peertube-input-text(340px);
-
-  display: block;
+input {
+  &[type=text] {
+    @include peertube-input-text(340px);
+  
+    display: block;
+  
+    &#name {
+      width: auto;
+      flex-grow: 1;
+    }
+  }
 
-  &#name {
-    width: auto;
-    flex-grow: 1;
+  &[type=submit] {
+    @include peertube-button;
+    @include orange-button;
+    margin-left: auto;
   }
 }
 
+label {
+  font-weight: $font-regular;
+  font-size: 100%;
+}
+
 textarea {
   @include peertube-textarea(500px, 150px);
 
   display: block;
 }
 
-.peertube-select-container {
-  @include peertube-select-container(340px);
+my-markdown-textarea ::ng-deep {
+  .root {
+    @media screen and (max-width: 1400px) {
+      flex-direction: column !important;
+    }
+  }
 }
 
-input[type=submit] {
-  @include peertube-button;
-  @include orange-button;
+.peertube-select-container {
+  @include peertube-select-container(340px);
 }
index 399350616bf1b4820eed3fc4715e8b849c456e2b..f1c13118452b82518ba76b12b2dda24445368846 100644 (file)
               <i class="ml-auto glyphicon glyphicon-menu-right"></i>
             </a>
 
-            <a ngbDropdownItem ngbDropdownToggle class="dropdown-item" routerLink="/my-account">
+            <a ngbDropdownItem ngbDropdownToggle class="dropdown-item" routerLink="/my-account/settings" fragment="video-settings">
               <my-global-icon iconName="video-lang"></my-global-icon>
               <ng-container i18n>Videos: {{ videoLanguages.join(', ') }}</ng-container>
               <i class="ml-auto glyphicon glyphicon-menu-right"></i>
             </a>
 
-            <a ngbDropdownItem ngbDropdownToggle class="dropdown-item" routerLink="/my-account">
+            <a ngbDropdownItem ngbDropdownToggle class="dropdown-item" routerLink="/my-account/settings" fragment="video-settings">
               <my-global-icon class="hover-display-toggle" [ngClass]="{ 'not-displayed': user.nsfwPolicy === 'display' }" iconName="sensitive"></my-global-icon>
               <my-global-icon class="hover-display-toggle" [ngClass]="{ 'not-displayed': user.nsfwPolicy !== 'display' }" iconName="unsensitive"></my-global-icon>
               <ng-container i18n>Sensitive: {{ nsfwPolicy }}</ng-container>
index f95ff5aba9e9139ba8946c9bc5a2b23c6d9d654a..5ed1ac6295a9ca051267e659d1704945ea1fd1b9 100644 (file)
   font-size: 13px;
 }
 
-.title-block .title-page {
-  margin-right: 0;
+.title-block {
+  .title-page {
+    margin-right: 0;
+  }
+  
+  my-feed {
+    display: inline-block;
+    margin-left: 5px;
+    opacity: 0;
+    transition: ease-in .2s opacity;
+  }
+  &:hover my-feed {
+    opacity: 1;
+  }
 }
 
 #dropdownSortComments {
   transform: translateY(-7%);
 }
 
-my-feed {
-  display: inline-block;
-  margin-left: 5px;
-}
-
 @media screen and (max-width: 600px) {
   .view-replies {
     margin-left: 46px;