This repository has been archived by the owner on Sep 11, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 78
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(tag-list): Fixes bug where more button displayed '0 More...' when…
… no tags were hidden.
- Loading branch information
1 parent
7bf2be8
commit 71e196c
Showing
9 changed files
with
125 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 32 additions & 0 deletions
32
apps/components-e2e/src/components/tag-list/tag-list.e2e.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
/** | ||
* @license | ||
* Copyright 2020 Dynatrace LLC | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
import { Selector } from 'testcafe'; | ||
import { waitForAngular } from '../../utils'; | ||
|
||
const tagList = Selector('#tagList'); | ||
|
||
fixture | ||
.only('Tag List') | ||
.page('http://localhost:4200/tag/tag-list') | ||
.beforeEach(async (testController: TestController) => { | ||
await testController.resizeWindow(1200, 800); | ||
await waitForAngular(); | ||
}); | ||
|
||
test("should not display '0 More...'", async (testController: TestController) => { | ||
await testController.expect(tagList.textContent).notContains('0 More...'); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<dt-tag-list id="tagList"> | ||
<dt-tag>Alpha</dt-tag> | ||
<dt-tag>Beta</dt-tag> | ||
<dt-tag>Gamma</dt-tag> | ||
<dt-tag>Delta</dt-tag> | ||
<dt-tag>Epsilon</dt-tag> | ||
<dt-tag>Zeta</dt-tag> | ||
<dt-tag>Eta</dt-tag> | ||
<dt-tag>Theta</dt-tag> | ||
<dt-tag-add></dt-tag-add> | ||
</dt-tag-list> |
31 changes: 31 additions & 0 deletions
31
apps/components-e2e/src/components/tag-list/tag-list.module.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
/** | ||
* @license | ||
* Copyright 2020 Dynatrace LLC | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
import { CommonModule } from '@angular/common'; | ||
import { NgModule } from '@angular/core'; | ||
import { Route, RouterModule } from '@angular/router'; | ||
import { DtTagModule } from '@dynatrace/barista-components/tag'; | ||
import { DtE2ETagList } from './tag-list'; | ||
|
||
const routes: Route[] = [{ path: '', component: DtE2ETagList }]; | ||
|
||
@NgModule({ | ||
declarations: [DtE2ETagList], | ||
imports: [CommonModule, RouterModule.forChild(routes), DtTagModule], | ||
exports: [], | ||
providers: [], | ||
}) | ||
export class DtE2ETagListModule {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
/** | ||
* @license | ||
* Copyright 2020 Dynatrace LLC | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
import { Component } from '@angular/core'; | ||
|
||
@Component({ | ||
selector: 'dt-e2e-tag-list', | ||
templateUrl: 'tag-list.html', | ||
}) | ||
export class DtE2ETagList {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters