mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ADF-2131] Search sorting (#3334)
* sorting configuration * detect primary sorting and use with document list * search results sorting * docs update * unit tests and code updates * update code * update code * generic sorting picker, test updates * ability to switch off client side sorting * update docs for document list
This commit is contained in:
committed by
Eugenio Romano
parent
73bc62ae8f
commit
07440731fa
43
docs/core/sorting-picker.component.md
Normal file
43
docs/core/sorting-picker.component.md
Normal file
@@ -0,0 +1,43 @@
|
||||
---
|
||||
Added: v2.4.0
|
||||
Status: Active
|
||||
---
|
||||
|
||||
# Sorting Picker Component
|
||||
|
||||
Provides an ability to pick one of the predefined sorting definitions and define sorting direction:
|
||||
|
||||
```html
|
||||
<adf-sorting-picker
|
||||
[options]="options"
|
||||
[selected]="value"
|
||||
[ascending]="ascending"
|
||||
(change)="onChanged($event)">
|
||||
</adf-sorting-picker>
|
||||
```
|
||||
|
||||

|
||||
|
||||
## Options format
|
||||
|
||||
You can bind a collection of any objects that expose the following properties:
|
||||
|
||||
```ts
|
||||
{
|
||||
key: string;
|
||||
label: string;
|
||||
}
|
||||
```
|
||||
|
||||
## Properties
|
||||
|
||||
| Name | Type | Default Value | Description |
|
||||
| options | `Array<{key: string, label: string}>` | `[]` | Available sorting options. |
|
||||
| selected | `string` | | Currently selected option key. |
|
||||
| ascending | `boolean` | true | Current sorting direction. |
|
||||
|
||||
## Events
|
||||
|
||||
| Name | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| change | `EventEmitter<{ key: string, ascending: boolean }>` | Raised each time sorting key or direction gets changed. |
|
Reference in New Issue
Block a user