Browse Source

Minor improvements

pull/5618/head
Thomas Kaul 2 weeks ago
parent
commit
b63c6ec61a
  1. 5
      libs/ui/src/lib/assistant/assistant.html
  2. 13
      libs/ui/src/lib/portfolio-filter-form/portfolio-filter-form.component.stories.ts
  3. 1
      libs/ui/src/lib/portfolio-filter-form/portfolio-filter-form.component.ts

5
libs/ui/src/lib/assistant/assistant.html

@ -172,7 +172,10 @@
[formControl]="dateRangeFormControl"
(selectionChange)="onChangeDateRange($event.value)"
>
@for (dateRangeOption of dateRangeOptions; track dateRangeOption) {
@for (
dateRangeOption of dateRangeOptions;
track dateRangeOption.value
) {
<mat-option [value]="dateRangeOption.value">{{
dateRangeOption.label
}}</mat-option>

13
libs/ui/src/lib/portfolio-filter-form/portfolio-filter-form.component.stories.ts

@ -1,3 +1,4 @@
import '@angular/localize/init';
import { Meta, moduleMetadata, StoryObj } from '@storybook/angular';
import { GfPortfolioFilterFormComponent } from './portfolio-filter-form.component';
@ -55,8 +56,16 @@ export const Default: Story = {
}
] as any,
tags: [
{ id: 'dividend', label: 'Dividend', type: 'TAG' },
{ id: 'tech', label: 'Technology', type: 'TAG' }
{
id: 'EMERGENCY_FUND',
label: 'Emergency Fund',
type: 'TAG'
},
{
id: 'RETIREMENT_FUND',
label: 'Retirement Fund',
type: 'TAG'
}
] as any,
disabled: false
}

1
libs/ui/src/lib/portfolio-filter-form/portfolio-filter-form.component.ts

@ -120,6 +120,7 @@ export class GfPortfolioFilterFormComponent
}
const tagControl = this.filterForm.get('tag');
if (this.tags.length === 0) {
tagControl?.disable({ emitEvent: false });
} else if (!this.disabled) {

Loading…
Cancel
Save