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.
feat(quick-filter): Add a new quick filter component inside an experi…
…mental package. The quick filter component is used to provide a quick way to operate with the filter field inside a sidebar. Inside the quick filter only an autocomplete with simple options can be displayed. This is part of an experimental package and not meant to be used inside production. The experimental package does not follow semantic versioning like the rest of the library does. This means that we might break the api in every version. It is only meant to be used for testing and feedback purpose. Fixes #453 Fixes #254
- Loading branch information
Lukas Holzer
committed
Mar 3, 2020
1 parent
5a9e886
commit 7cc2892
Showing
55 changed files
with
2,400 additions
and
228 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
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
8 changes: 8 additions & 0 deletions
8
...-e2e/src/components/quick-filter/quick-filter-initial-data/quick-filter-initial-data.html
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,8 @@ | ||
<dt-quick-filter [dataSource]="_dataSource" [filters]="_initialFilters"> | ||
<dt-quick-filter-title>Quick-filter</dt-quick-filter-title> | ||
<dt-quick-filter-sub-title> | ||
All options in the filter field above | ||
</dt-quick-filter-sub-title> | ||
|
||
my content | ||
</dt-quick-filter> |
44 changes: 44 additions & 0 deletions
44
...ts-e2e/src/components/quick-filter/quick-filter-initial-data/quick-filter-initial-data.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,44 @@ | ||
/** | ||
* @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'; | ||
import { DtQuickFilterDefaultDataSource } from '@dynatrace/barista-components/experimental/quick-filter'; | ||
import { FILTER_FIELD_TEST_DATA } from '@dynatrace/testing/fixtures'; | ||
|
||
@Component({ | ||
selector: 'dt-e2e-quick-filter', | ||
templateUrl: 'quick-filter-initial-data.html', | ||
}) | ||
export class DtE2EQuickFilterInitialData { | ||
_dataSource = new DtQuickFilterDefaultDataSource(FILTER_FIELD_TEST_DATA, { | ||
showInSidebar: () => true, | ||
}); | ||
|
||
_initialFilters = [ | ||
[ | ||
FILTER_FIELD_TEST_DATA.autocomplete[0], | ||
FILTER_FIELD_TEST_DATA.autocomplete[0].autocomplete![1], | ||
], | ||
[ | ||
FILTER_FIELD_TEST_DATA.autocomplete[1], | ||
FILTER_FIELD_TEST_DATA.autocomplete[1].autocomplete![2], | ||
], | ||
]; | ||
|
||
constructor() { | ||
console.log(this._initialFilters); | ||
} | ||
} |
Oops, something went wrong.