Skip to content

Commit 1bf1a87

Browse files
pomahtrivladaskorohodovadirkpieterse
authored
CardView - demos - descriptions (DevExpress#30003)
Signed-off-by: Vlada Skorokhodova <[email protected]> Co-authored-by: Vlada Skorokhodova <[email protected]> Co-authored-by: Vlada Skorokhodova <[email protected]> Co-authored-by: dirkpieterse <[email protected]>
1 parent 89d84d3 commit 1bf1a87

File tree

14 files changed

+98
-20
lines changed

14 files changed

+98
-20
lines changed
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Card templates allow you to display custom content in cards. In this demo, a [cardTemplate](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/#cardTemplate) adds car images and additional content (such as badges) to regular cards.
2+
<!--split-->
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
To change field visibility at runtime, set the **columnChooser**.[enabled](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/columnChooser/#enabled) property to `true`. To ensure specific fields remain visible, set the **columns[]**.[allowHiding](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/columns/#allowHiding) property to `false`.
2+
<!--split-->
3+
4+
To display the column chooser, click the toolbar button above the CardView. You can specify the column chooser's position with the **columnChooser**.[position](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/columnChooser/#position) property. Changing how users display or hide columns depends on **columnChooser**.[mode](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/columnChooser/#mode):
5+
6+
* *"dragAndDrop"*
7+
Users drag and drop fields between the header panel and column chooser.
8+
9+
* *"select"*
10+
Users toggle check boxes for field names.
11+
12+
If the column chooser contains multiple hidden columns, assign `true` to the **search**.[enabled](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/columnChooser/search/#enabled) property to enable the DevExtreme field search UI.
13+
14+
In this demo, use the checkboxes above the CardView to toggle search and selection features.
15+
16+
To hide a field programmatically, change **columns[]**.[visible](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/columns/#visible) property to `false`.
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
DevExtreme CardView includes a header filter which allows users to filter cards by field values. Click the header filter icon in the CardView's header panel to open the pop-up menu.
2+
<!--split-->
3+
4+
### Display Header Filter Icons
5+
6+
Assign `true` to the **headerFilter**.[visible](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/headerFilter/#visible) property to display header filter icons for all CardView fields. To hide the icon for a specific field, set the [allowHeaderFiltering](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/columns/#allowHeaderFiltering) property to `false`.
7+
8+
### Enable Search UI Within Header Filters
9+
10+
CardView offers a text-based search to find specific values in a header filter. Define the [search](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/headerFilter/search/) property in the **headerFilter** object or a **columns**.[headerFilter](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/columns/headerFilter/) object to configure this capability.
11+
12+
The search panel checks for values only within the same data field. To expand the search to additional fields, use **search**.[searchExpr](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/columns/headerFilter/search/#searchExpr) property. For example, this demo allows you to enter a state name in the City column's header filter. You can then see a list of all cities within the specified state and select city names that you want to use as a filter.
13+
14+
To apply a comparison operation used to search header filter values, specify the **search**.[mode](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/columns/headerFilter/search/#mode) property.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
DevExtreme CardView fields use the same display order as data fields in the component's [dataSource](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/#dataSource). You can specify a different display order with the [columns[]](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/columns/) array. To reorder a field at runtime, change the **columns[]**.[visibleIndex](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/columns/#visibleIndex) property.
2+
<!--split-->
3+
4+
To allow users to reorder fields, set [allowColumnReordering](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/#allowColumnReordering) to `true`. To disable reordering operations for a specific field, assign `false` to its [allowReordering](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/columns/#allowReordering) property.
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
CardView allows you to validate user input. You can apply pre-defined [validation rules](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/columns/#validationRules) or custom rules to individual columns.
2+
<!--split-->
3+
4+
In this demo, the following rules are used:
5+
6+
- [required](/Documentation/ApiReference/UI_Components/dxValidator/Validation_Rules/RequiredRule/)
7+
Specifies that field values should not be empty.
8+
- [pattern](/Documentation/ApiReference/UI_Components/dxValidator/Validation_Rules/PatternRule/)
9+
Specifies a pattern that field values should match.
10+
- [email](/Documentation/ApiReference/UI_Components/dxValidator/Validation_Rules/EmailRule/)
11+
Specifies that field values match the Email pattern.
12+
- [async](/Documentation/ApiReference/UI_Components/dxValidator/Validation_Rules/AsyncRule/)
13+
Specifies custom validation parameters that are used to validate a value on the server.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
Field templates allow you to display custom content in field elements. Use the [fieldTemplate](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/columns/#fieldTemplate) property to configure these templates.
2+
3+
In this demo, custom field templates are configured to customize the appearance of the 'Priority', 'Assigned to', and 'Completed' fields.
4+
<!--split-->
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
The [filter panel](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/filterPanel/) is a UI element that displays the combined filter. This filter is stored in the [filterValue](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/#filterValue) property and includes filters that users apply in other UI elements ([header filter](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/headerFilter/), [filterBuilder](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/#filterBuilder)).
2+
3+
To display the filter panel, set the **filterPanel**.[visible](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/filterPanel/#visible) property to `true`.
4+
5+
A click on the combined filter calls the integrated filter builder. You can configure it in the [filterBuilder](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/#filterBuilder) object. In this demo, this object is used to add the `weekends` [custom filter operation](/Documentation/ApiReference/UI_Components/dxFilterBuilder/Configuration/customOperations).
6+
<!--split-->

apps/demos/Demos/CardView/Overview/description.md

Lines changed: 0 additions & 20 deletions
This file was deleted.
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
CardView can display a popup edit form. The form can include any fields from the bound data source, regardless of whether the corresponding column is visible in the grid (see the `Notes` and `Address` columns).
2+
3+
To enable this behavior in your application, set the following properties to `true`:
4+
- [editing](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/editing/).[allowUpdating](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/editing/#allowUpdating)
5+
- **editing**.[allowAdding](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/editing/#allowAdding)
6+
- **editing**.[allowDeleting](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/editing/#allowDeleting)
7+
<!--split-->
8+
9+
CardView uses the DevExtreme [Form](/Documentation/ApiReference/UI_Components/dxForm/) and [Popup](/Documentation/ApiReference/UI_Components/dxPopup/) components to display the form and the popup. Their default configurations are defined automatically. If these configurations do not meet your requirements, you can redefine them in the **editing** object's [form](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/editing/#form) and [popup](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/editing/#popup) properties as shown in this demo.
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
To enable user data search, activate the [searchPanel](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/searchPanel/) by setting its [visible](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/searchPanel/#visible) property to `true`.
2+
3+
CardView searches through all fields, whether they are [visible](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/columns/#visible) or hidden. To search only visible fields, enable the **searchPanel**.[searchVisibleColumnsOnly](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/searchPanel/#searchVisibleColumnsOnly) property. To omit specific fields, set their [allowSearch](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/columns/#allowSearch) property to `false`.
4+
<!--split-->
5+
6+
Numeric, date, and Boolean values match only if they are equal to the search query. String values match if they contain the query. Search for strings is case-insensitive.
7+
8+
To specify a search query in code, set the **searchPanel**.[text](/Documentation/ApiReference/UI_Components/dxCardView/Configuration/searchPanel/#text) property or call the [searchByText(text)](/Documentation/ApiReference/UI_Components/dxCardView/Methods/#searchByTexttext) method.

0 commit comments

Comments
 (0)