Unplanned
Last Updated: 10 Aug 2020 13:02 by ADMIN
Ralph
Created on: 07 Aug 2020 21:05
Category: Date/Time Pickers
Type: Bug Report
0
DatePicker issue when kendo namespace is set

I was able to duplicate an issue I found when we upgraded to the latest Kendo UI for jQuery release. The DatePicker is not working correctly when the kendo namespace, kendo.ns, is set. I was able to duplicate it using the MVVM demo example for DatePicker. The month is no longer displayed and clicking on the Month to zoom out in time stops working as well. I have not checked what other functionality is not working. I do know the parsing is working properly as well as formatting.

<!DOCTYPE html>
<html>
<head>
    <base href="https://demos.telerik.com/kendo-ui/datepicker/mvvm">
    <style>html { font-size: 14px; font-family: Arial, Helvetica, sans-serif; }</style>
    <title></title>
    <link rel="stylesheet" href="https://kendo.cdn.telerik.com/2020.2.617/styles/kendo.common.min.css" />
    <link rel="stylesheet" href="https://kendo.cdn.telerik.com/2020.2.617/styles/kendo.metroblack.min.css" />
    <link rel="stylesheet" href="https://kendo.cdn.telerik.com/2020.2.617/styles/kendo.metroblack.mobile.min.css" />

    <script src="https://kendo.cdn.telerik.com/2020.2.617/js/jquery.min.js"></script>
    
    
    <script src="https://kendo.cdn.telerik.com/2020.2.617/js/kendo.all.min.js"></script>
    
    

    <link rel="stylesheet" href="../content/shared/styles/examples-offline.css">
    <script src="../content/shared/js/console.js"></script>
  <script>
  // set the kendo namespace so not to collide with other libraries
  kendo.ns = "kendo-";
</script>
</head>
<body>
<div id="example">
    <div class="demo-section k-content">
        <div>
            <h4>Choose a date</h4>
            <input data-kendo-role="datepicker"
                   data-kendo-bind="visible: isVisible,
                              enabled: isEnabled,
                              value: selectedDate,
                              events: { change: onChange }"
                   style="width: 100%">
        </div>
        <div style="padding-top: 2em;">
            <h4>Console</h4>
            <div class="console"></div>
        </div>
    </div>
    <div class="box">
        <div class="box-col">
            <h4>Configuration</h4>
            <div>
                <label><input type="checkbox" data-bind="checked: isEnabled">Enable</label>
            </div>
            <div>
                <label><input type="checkbox" data-bind="checked: isVisible">Visible</label>
            </div>
        </div>
        <div class="box-col">
            <h4>Information</h4>
            Kendo UI DatePicker supports the
            <a href="https://docs.telerik.com/kendo-ui/getting-started/framework/mvvm/bindings/enabled">enabled</a>,
            <a href="https://docs.telerik.com/kendo-ui/getting-started/framework/mvvm/bindings/events">events</a>,
            <a href="https://docs.telerik.com/kendo-ui/getting-started/framework/mvvm/bindings/value">value</a> and
            <a href="https://docs.telerik.com/kendo-ui/getting-started/framework/mvvm/bindings/visible">visible</a> bindings.
        </div>
    </div>
<script>
    var viewModel = kendo.observable({
        selectedDate: null,
        isEnabled: true,
        isVisible: true,
        onChange: function() {
            kendoConsole.log("event :: change (" + kendo.toString(this.get("selectedDate"), "D") + ")");
        }
    });
    kendo.bind($("#example"), viewModel);
</script>
</div>


</body>
</html>
1 comment
ADMIN
Alex Hajigeorgieva
Posted on: 10 Aug 2020 13:02

Hi, Ralph,

Thank you very much for reporting this behaviour to us.

It seems to be a side effect of the new modern rendering of the DatePickers we introduced in 2020 R2. I have converted this thread to a public feedback item which will allow it to be discoverable and updated your Telerik points as a token of appreciation for helping us improve.

If you prefer to subscribe to GitHub, this feedback item is synced with this issue:

https://github.com/telerik/kendo-ui-core/issues/5963

Please accept our apology for the inconvenience.

Kind Regards,
Alex Hajigeorgieva
Progress Telerik