Skip to content

Commit

Permalink
Merge pull request #14943 from Kisters-BS/fix/docParameters
Browse files Browse the repository at this point in the history
Fixed  #14942 - Only showing first parameter
  • Loading branch information
cetincakiroglu authored Mar 13, 2024
2 parents 3019f89 + 237fc4a commit c90dc03
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 16 deletions.
2 changes: 1 addition & 1 deletion src/app/showcase/layout/doc/app.docapisection.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,7 @@ export class AppDocApiSection {
setEmitData(emitters) {
return emitters.map((emitter) => ({
name: emitter.name,
parameters: { name: emitter.parameters[0]?.name, type: emitter.parameters[0]?.type },
parameters: emitter.parameters,
description: emitter.description,
deprecated: emitter.deprecated
}));
Expand Down
32 changes: 17 additions & 15 deletions src/app/showcase/layout/doc/app.docapitable.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,21 +33,23 @@ import { AppConfigService } from '../../service/appconfigservice';
></span>
<span *ngIf="entry[0] === 'type'" class="doc-option-type">{{ entry[1] || '-' }}</span>
<ng-container *ngIf="entry[0] === 'parameters'">
<div class="doc-option-params" *ngIf="entry[1].name; else nullValue">
<span *ngIf="entry[1].name" [ngClass]="{ 'doc-option-parameter-name': label === 'Emitters', 'text-primary-700': label === 'Templates' }">{{ entry[1].name }} :</span>
<ng-container *ngFor="let value of getType(entry[1].type); let i = index"
>{{ i !== 0 ? ' |' : ' ' }}
<a
*ngIf="isLinkType(value); else elseBlock"
(click)="scrollToLinkedElement($event, value, prop)"
[ngClass]="{ 'doc-option-parameter-type': label === 'Emitters', 'text-primary-700': label === 'Templates' }"
>{{ value || '-' }}</a
>
<ng-template #elseBlock>
<span [ngClass]="{ 'doc-option-parameter-type': label === 'Emitters', 'text-primary-700': label === 'Templates' }">{{ value }}</span>
</ng-template>
</ng-container>
</div>
<ng-container *ngFor="let parameter of entry[1]" >
<div class="doc-option-params" *ngIf="parameter.name; else nullValue">
<span *ngIf="parameter.name" [ngClass]="{ 'doc-option-parameter-name': label === 'Emitters', 'text-primary-700': label === 'Templates' }">{{ parameter.name }} :</span>
<ng-container *ngFor="let value of getType(parameter.type); let i = index"
>{{ i !== 0 ? ' |' : ' ' }}
<a
*ngIf="isLinkType(value); else elseBlock"
(click)="scrollToLinkedElement($event, value, prop)"
[ngClass]="{ 'doc-option-parameter-type': label === 'Emitters', 'text-primary-700': label === 'Templates' }"
>{{ value || '-' }}</a
>
<ng-template #elseBlock>
<span [ngClass]="{ 'doc-option-parameter-type': label === 'Emitters', 'text-primary-700': label === 'Templates' }">{{ value }}</span>
</ng-template>
</ng-container>
</div>
</ng-container>
<ng-template #nullValue>
<span>null</span>
</ng-template>
Expand Down

0 comments on commit c90dc03

Please sign in to comment.