Telerik Forums
Kendo UI for jQuery Forum
1 answer
602 views

Hi Team,

I would like to get selected text along with html tags but getting only plain text by using

editor.getSelection() or editor.getRange() methods. Please help me to get html selected text 
Georgi Denchev
Telerik team
 answered on 28 Mar 2023
1 answer
107 views

Hi all,

I have a JSON tree with 3 levels of depth that I want to transform into a TreeView with checkboxes. This tree is sent by a server and the nodes contain certain metadata that will help me to format the output. More specifically, if a node has "isshop" to 1, or "isshop" is 0 but "_chn" is 1, then I have to include it. If the node is not a shop and has no children I should not output it.

The issue is that using templates the most I have been able to reach is having gaps in the view where the filtered nodes should have been without applying conditions. Here is my template:

<script id="tvCentrosTmpl" type="text/kendo-ui-template">
    # if (item.isshop == 1 || (item.isshop == 0 && item._chn)) { #
        <div class="spnNameCentro" data-idmodel="#:item.id#" data-uid="#:item.uid#" data-type="#:item.type#" data-isshop="#:item.isshop#">#:item.name#</div>
    # } #
</script>

And in the checkboxes definition I am using this:

template: function(data){
    if (data.item.isshop == 1 || (data.item.isshop == 0 && data.item._chn))
    {
        return '<input type="checkbox" class="chkParams" data-id="' + data.item.id + '" data-isshop="' + data.item.isshop + '" onclick="srcInhibMasivas.chkCenter_click(this);" />'
    }
    return '';
}

Here is an example output where "Z03" has no children and is not a shop:

Is there any way to leave the undesired nodes out without having to traverse and process the JSON client-side?

Thank you very much, best regards.

Neli
Telerik team
 answered on 28 Mar 2023
0 answers
722 views

Hi,

I am using kendo popover to display some dynamic messages in my app.

I show kendo popover based on my local event and display message. I want it to stay visible until user specifically uses "close" action button within the popover.

However, whatever I do, the moment user clicks outside popover, it is closed. 

My page consists from header bar (not visible or same for pages), and I want to "anchor" my popover to it. So, when it's there, popover should appear and remain visible. 

For obvious reasons, I can't make my whole page to be container, because it makes no sense.

I tried preventing default on hide event, but result is the same.

Please could you tell me how to do this? I easily achieved this on popover for angular.

 

Thank you in advance.

Regards,

Vedad

Vedad
Top achievements
Rank 3
Bronze
Bronze
Iron
 asked on 27 Mar 2023
1 answer
215 views

Hi,

I have a licensed kendo 2019 version in my application. Since Kendo provides individual scripts to include rather than the entire library ,I have the required  Chart Scripts in my ASP.NET MVC application.

I have upgraded the version from 2019 to the latest 2023.1.314. The 2023 upgrade includes a lot of breaking changes that includes a bunch of individual .js files. In summary, now it only needs to have:

  • Theme based css (default-main.css)
  • Jquery (The current version in my application is 3.6.4)
  • kendo.all.min.js

Including the above 3 works as expected. However ,when using just the individual scripts for charts rather than the whole set of library which is a huge file, the kendo.drawing.js file breaks .Attachment includes the snapshot for the error.

So the question is, with the 2023 upgrade, Do I have to use kendo.all.min.js rather than using the individual scripts for just the components I have?

Martin
Telerik team
 answered on 27 Mar 2023
1 answer
502 views

As recently as version 2022.3.1109, I could set a grid column attribute (e.g. class) to a template and easily get conditional formatting like different cell background colors depending on value:

    columns: [
                    { field: "OrderDate", title: "Order Date", format: "{0:MM/dd/yyyy}" },
                    { field: "Freight",  
                      attributes: { 
                                    class: "#: ClassFromFreight(data.Freight) #" 
                                  } 
                    }      

DEMO

Since 2023.1.117, this no longer seems to work. Was this an intentional change? Is there another way to do this now?

DEMO with 2023.1.314

Nikolay
Telerik team
 answered on 27 Mar 2023
1 answer
128 views

https://www.telerik.com/kendo-angular-ui/components/dropdowns/multiselect/checkboxes/ (looking to implement something like this but with Kendo UI for jQuery)

I am looking to implement a multi-select with checkboxes. I found kendo provides an option for Angular, but I am looking to see if this is provided with Kendo UI for jQuery, if so, any documentation I can look into?

I am also looking to add, a Select All checkbox which will select all options if checked, if unchecked, need to unselect all the options. Is there any built-in functionality to achieve this?

 

Neli
Telerik team
 answered on 24 Mar 2023
1 answer
111 views
I'm attempting to use Kendo UI to implement the Fibonacci sequence, however, I'm having speed difficulties while computing higher Fibonacci numbers. Here's an illustration of my code:
function fibonacci(num) {
  if (num <= 1) {
    return 1;
  }
  return fibonacci(num - 1) + fibonacci(num - 2);
}

var series = [];
for (var i = 0; i < 10; i++) {
  series.push(fibonacci(i));
}
console.log(series);
I'm using a recursive function in this code to compute the Fibonacci sequence up to the tenth number and save the results in an array. When I try to calculate greater Fibonacci numbers, however, the performance of my code suffers. For example, if I update the loop to compute the first 50 Fibonacci numbers, the code runs slowly. 
I saw an article that suggested using an iterative method rather than a recursive approach. Is it going to work? Could someone please assist me?
Ivan Zhekov
Telerik team
 answered on 23 Mar 2023
0 answers
106 views

Hello there,

We are currently having a logic in place where we load initial grid data and then process additional data after which we refresh the grid in order to see that additional data. Is there a way to do this without grid refresh?

-Stevan

Stevan
Top achievements
Rank 1
 asked on 23 Mar 2023
0 answers
105 views

Have just tripped over an little issue with the columns.attributes & columns.headerAttributes demos not working as expected.

To demonstrate run the following dojos based on your API demos

https://dojo.telerik.com/ojIrefaF
https://dojo.telerik.com/IGIBaViH

and you will see neither the header or cell data is being aligned to the right.

This regression seems to have been introduced with the 2022.2.802 release when the .k-text-right class went from

.k-text-right {
    text-align: right!important;
}

to

.k-text-right {
    text-align: right ;
}

Now there was probably a good reason to remove the '!important' property but anybody running these demos now will be confused with the output.

Looking at the latest CSS (2023.1.314) I see you now have a '!k-text-right' style for this purpose so it looks like a little tweak to you demo pages is required.

May I also suggest you add a note in the Grid API documentation about 'CSS Specificity' because I suspect nine times out of ten the '!important' property will be required to ensure it is not overridden by any Kendo CSS.

Regards
Alan

       
AGB
Top achievements
Rank 1
Iron
 asked on 22 Mar 2023
0 answers
216 views

I have just seen the demo about using kendo DatePicker. But when inspect the calendar icon under Accessibility menu I can see the Default name for the button is given as "select". I would like to change the name of button from "select" to "Pick a date". Please Guide through. I have attached image for your reference.

Following is the code snippet:

<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8"/>
    <title>Kendo UI Snippet</title>

    <link rel="stylesheet" href="https://kendo.cdn.telerik.com/themes/6.2.0/default/default-ocean-blue.css"/>

    <script src="https://code.jquery.com/jquery-3.4.1.min.js"></script>
    <script src="https://kendo.cdn.telerik.com/2023.1.314/js/kendo.all.min.js"></script>
</head>
<body>
  
    <input id="datePicker" />

    <script>    
        $("#datePicker").kendoDatePicker({        
            value: new Date(2022, 0, 3),
            min: new Date(2022, 0, 1),
            max: new Date(2022, 5, 30),
            weekNumber: true,
            format: "yyyy-MM-dd"
        });
    </script>
</body>
</html>
Pratik
Top achievements
Rank 1
 updated question on 22 Mar 2023
Narrow your results
Selected tags
Tags
Grid
General Discussions
Charts
Data Source
Scheduler
DropDownList
TreeView
MVVM
Editor
Window
DatePicker
Spreadsheet
Upload
ListView (Mobile)
ComboBox
TabStrip
MultiSelect
AutoComplete
ListView
Menu
Templates
Gantt
Validation
TreeList
Diagram
NumericTextBox
Splitter
PanelBar
Application
Map
Drag and Drop
ToolTip
Calendar
PivotGrid
ScrollView (Mobile)
Toolbar
TabStrip (Mobile)
Slider
Button (Mobile)
Filter
SPA
Drawing API
Drawer (Mobile)
Globalization
LinearGauge
Sortable
ModalView
Hierarchical Data Source
Button
FileManager
MaskedTextBox
View
Form
NavBar
Notification
Switch (Mobile)
SplitView
ListBox
DropDownTree
PDFViewer
Sparkline
ActionSheet
TileLayout
PopOver (Mobile)
TreeMap
ButtonGroup
ColorPicker
Pager
Styling
MultiColumnComboBox
Chat
DateRangePicker
Dialog
Checkbox
Timeline
Drawer
DateInput
ProgressBar
MediaPlayer
ImageEditor
TextBox
OrgChart
Effects
Accessibility
PivotGridV2
ScrollView
BulletChart
Licensing
QRCode
ResponsivePanel
Switch
Wizard
CheckBoxGroup
TextArea
Barcode
Breadcrumb
Collapsible
Localization
MultiViewCalendar
Touch
RadioButton
Stepper
Card
ExpansionPanel
Rating
RadioGroup
Badge
Captcha
Heatmap
AppBar
Loader
Security
TaskBoard
Popover
DockManager
FloatingActionButton
CircularGauge
ColorGradient
ColorPalette
DropDownButton
TimeDurationPicker
ToggleButton
TimePicker
AICodingAssistant
BottomNavigation
Ripple
SkeletonContainer
Avatar
Circular ProgressBar
FlatColorPicker
SplitButton
Signature
Chip
ChipList
VS Code Extension
AIPrompt
PropertyGrid
Sankey
Chart Wizard
OTP Input
SpeechToTextButton
InlineAIPrompt
StockChart
ContextMenu
DateTimePicker
RadialGauge
ArcGauge
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?