Skip to content

Commit

Permalink
[ACS-8638] - [ACC] User is able to 'select' tag chip while creating n…
Browse files Browse the repository at this point in the history
…ew tags in ACC
  • Loading branch information
dominikiwanekhyland committed Aug 29, 2024
1 parent 075589c commit dd39e81
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
</p>
<div class="adf-tags-list" [class.adf-tags-list-fixed]="!tagNameControlVisible" #tagsList>
<mat-chip-listbox *ngIf="tags.length > 0">
<mat-chip-option *ngFor="let tag of tags" [disableRipple]="true" [title]="tag" class="adf-tags-chip">
<mat-chip *ngFor="let tag of tags" [disableRipple]="true" [title]="tag" class="adf-tags-chip">
{{ tag }}
<button
data-automation-id="remove-tag-button"
Expand All @@ -28,7 +28,7 @@
matChipRemove>
<mat-icon>close</mat-icon>
</button>
</mat-chip-option>
</mat-chip>
</mat-chip-listbox>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,10 @@ adf-tags-creator {
margin-top: 8px;
}

.adf-tags-chip {
height: auto;
}

.adf-existing-tags-panel {
border-top-left-radius: 6px;
border-top-right-radius: 6px;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ import { NoopAnimationsModule } from '@angular/platform-browser/animations';
import { HarnessLoader } from '@angular/cdk/testing';
import { TestbedHarnessEnvironment } from '@angular/cdk/testing/testbed';
import { MatProgressSpinnerHarness } from '@angular/material/progress-spinner/testing';
import { MatChipOptionHarness } from '@angular/material/chips/testing';
import { MatChipHarness } from '@angular/material/chips/testing';

describe('TagsCreatorComponent', () => {
let fixture: ComponentFixture<TagsCreatorComponent>;
Expand Down Expand Up @@ -105,7 +105,7 @@ describe('TagsCreatorComponent', () => {
* @returns list of tags
*/
async function getAddedTags(): Promise<string[]> {
const matChipHarness = await loader.getAllHarnesses(MatChipOptionHarness.with({ selector: '.adf-tags-chip' }));
const matChipHarness = await loader.getAllHarnesses(MatChipHarness.with({ selector: '.adf-tags-chip' }));
const tagElements = [];
for (const matChip of matChipHarness) {
tagElements.push(await matChip.getText());
Expand Down

0 comments on commit dd39e81

Please sign in to comment.