All files / app/form/plugins/gen gen.component.html

34.69% Statements 17/49
44.82% Branches 13/29
0% Functions 0/1
48.27% Lines 14/29

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 472x 2x 2x 2x     2x 1x 2x         2x       1x   1x                   2x                   1x 2x         1x  
@if (plugins && plugin) {
  <label [title]="plugin.config?.description">{{ plugin.config?.submitChild || plugin.name || plugin.tag }}</label>
  @if (group) {
    @if (children.length) {
      <div class="ribbon-margin" [style.margin-bottom.px]="childrenOn * 20"></div>
    }
    @if (form || promoteAdvanced && advancedForm) {
      <formly-form class="form plugin-content"
                   [model]="model"
                   [form]="group"
                   [fields]="form || advancedForm!"
                   [options]="options"></formly-form>
    }
    @if (advancedForm && (form || !promoteAdvanced)) {
      <details class="advanced {{ cssClass(plugin.tag) }}"
               [class.mini]="!form">
        @if (form) {
          <summary><span i18n>Advanced</span></summary>
        } @else {
          <summary i18n-title title="Advanced"><span></span></summary>
        }
        <formly-form class="form plugin-content"
                     [model]="model"
                     [form]="group"
                     [fields]="advancedForm"
                     [options]="options"></formly-form>
      </details>
    }
  }
  @for (child of children; track child.tag) {
    @if (plugins.contains(child.tag)) {
      <hr>
      <div>
        <app-form-gen [plugins]="plugins" [plugin]="child"></app-form-gen>
      </div>
    }
  }
}
 
<div class="floating-ribbons">
  @for (child of children; track child.tag) {
    <div class="icon {{ cssClass(child.tag) }}"
         [class.on]="plugins.contains(child.tag)"
         (click)="toggleChild(child.tag)"><span>{{ child.config?.submitChild }}</span></div>
  }
</div>