瀏覽代碼

✨ hide schema selector under "advanced"

jmacura 4 年之前
父節點
當前提交
0fdae9aec2
共有 2 個文件被更改,包括 7 次插入1 次删除
  1. 6 1
      src/adjuster/adjuster.component.html
  2. 1 0
      src/adjuster/adjuster.component.ts

+ 6 - 1
src/adjuster/adjuster.component.html

@@ -34,7 +34,12 @@
         <option *ngFor="let problem of adjusterPresetsService.getActiveRoleProblems()" [ngValue]="problem">{{problem.labels[0]['@value']}}</option>
       </select>
     </div>
-    <div class="p-2 center-block">
+    <button class="btn btn-secondary btn-sm" aria-expanded="false" aria-controls="advancedOptions" (click)="showAdvancedOptions = !showAdvancedOptions">
+      <span class="glyphicon cursor-pointer" [ngClass]="showAdvancedOptions ? 'icon-chevron-down' : 'icon-chevron-right'">
+      </span>
+      Advanced
+    </button>
+    <div class="p-2 center-block" [hidden]="!showAdvancedOptions">
       Classify factors by schema:&emsp;
       <select class="form-select" [(ngModel)]="adjusterPresetsService.activeSchema" (ngModelChange)="adjusterPresetsService.changeSchema($event)">
         <option *ngFor="let schema of adjusterPresetsService.schemas" [ngValue]="schema">{{schema.labels[0]['@value']}}</option>

+ 1 - 0
src/adjuster/adjuster.component.ts

@@ -20,6 +20,7 @@ export class AdjusterComponent implements HsPanelComponent, OnInit {
   //descriptionVisible: boolean;
   errorMsg: string;
   //method: string;
+  showAdvancedOptions = false;
   viewRef: ViewRef;
 
   constructor(