You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/api/javascript/ui/datepicker.md
+10-32Lines changed: 10 additions & 32 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -101,7 +101,7 @@ The effect(s) to use when playing the open animation. Multiple effects should be
101
101
102
102
The duration of the open animation in milliseconds.
103
103
104
-
### ARIATemplate `String`*(default: "Current focused #=data.valueType# is #=data.text#")*
104
+
### ARIATemplate `String`*(default: "Current focused ${valueType} is ${text}")*
105
105
106
106
Specifies a template used to populate the value of the aria-label attribute of the currently focused cell of the calendar. The parameters available for the template are:
107
107
@@ -114,7 +114,7 @@ The duration of the open animation in milliseconds.
@@ -988,76 +991,39 @@ Specifies a static HTML content, which will be rendered as a header of the popup
988
991
989
992
The [template](/api/javascript/kendo/methods/template) used to render the items. By default the widget displays only the text of the data item (configured via `dataTextField`).
#### Example - specify template as a string literal
1013
995
1014
996
<input id="dropdownlist" />
1015
997
<script>
998
+
let encode = kendo.htmlEncode;
1016
999
$("#dropdownlist").kendoDropDownList({
1017
1000
dataSource: [
1018
1001
{ id: 1, name: "Apples" },
1019
1002
{ id: 2, name: "Oranges" }
1020
1003
],
1021
1004
dataTextField: "name",
1022
1005
dataValueField: "id",
1023
-
template: '<span><img src="/img/#: id #.png" alt="#: name #" />#: name #</span>'
1006
+
template: ({ id, name }) => `<span><img src="/img/${id}.png" alt="${name}" />${name}</span>`
1024
1007
});
1025
1008
</script>
1026
1009
1027
1010
### valueTemplate `String|Function`
1028
1011
1029
1012
The [valueTemplate](/api/javascript/kendo/methods/template) used to render the selected value. By default the widget displays only the text of the data item (configured via `dataTextField`).
1030
1013
1031
-
#### Example - specify valueTemplate as a function
0 commit comments