mirror of
https://github.com/hanzoai/jube-fork.git
synced 2026-11-02 09:25:40 +00:00
83 lines
2.7 KiB
HTML
Executable File
83 lines
2.7 KiB
HTML
Executable File
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<title>Cell comments</title>
|
|
<meta charset="utf-8">
|
|
<link href="../content/shared/styles/examples-offline.css" rel="stylesheet">
|
|
<link href="../../styles/kendo.common.min.css" rel="stylesheet">
|
|
<link href="../../styles/kendo.rtl.min.css" rel="stylesheet">
|
|
<link href="../../styles/kendo.default.min.css" rel="stylesheet">
|
|
<link href="../../styles/kendo.default.mobile.min.css" rel="stylesheet">
|
|
<script src="../../js/jquery.min.js"></script>
|
|
<script src="../../js/jszip.min.js"></script>
|
|
<script src="../../js/kendo.all.min.js"></script>
|
|
<script src="../content/shared/js/console.js"></script>
|
|
<script>
|
|
|
|
</script>
|
|
|
|
|
|
</head>
|
|
<body>
|
|
|
|
<a class="offline-button" href="../index.html">Back</a>
|
|
|
|
<div id="example">
|
|
<div class="configurator">
|
|
<div class="header">Configurator</div>
|
|
<div class="box-col">
|
|
<h4>Cell comments</h4>
|
|
<ul class="options">
|
|
<li>
|
|
<button id="toggle">Click to add / remove comment from A2 cell</button>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div id="spreadsheet" style="width: 100%;height:380px"></div>
|
|
<script>
|
|
$(function () {
|
|
var spreadsheet = $("#spreadsheet").kendoSpreadsheet({
|
|
sheetsbar: false,
|
|
excel: {
|
|
// Required to enable Excel Export in some browsers
|
|
proxyURL: "https://demos.telerik.com/kendo-ui/service/export"
|
|
},
|
|
sheets: [{
|
|
columns: [{
|
|
width: 300
|
|
}],
|
|
rows: [{
|
|
cells: [{
|
|
value: "This cell has a comment.",
|
|
bold: true,
|
|
comment: "Comment set on the cell with the Spreadsheet initialization."
|
|
}]
|
|
}, {
|
|
cells: [{
|
|
value: "This cell will get a comment on button click.",
|
|
bold: true
|
|
}]
|
|
}]
|
|
}]
|
|
}).data("kendoSpreadsheet");
|
|
|
|
$("#toggle").click(function () {
|
|
var range = spreadsheet.activeSheet().range("A2");
|
|
var comment = range.comment();
|
|
|
|
if (comment === null) {
|
|
range.comment("Comment added using range API call");
|
|
} else {
|
|
range.comment(null);
|
|
}
|
|
});
|
|
});
|
|
</script>
|
|
</div>
|
|
|
|
|
|
|
|
</body>
|
|
</html>
|