Category / Section
How to disable the ribbon collapse icon in the JavaScript Spreadsheet
1 min read
This knowledge base explains how to disable the ribbon collapse symbol from the JavaScript Spreadsheet toolbar. You can achieve this by adding “display: none” to the drop-down icon span element in the spreadsheet ribbon, as shown below.
[HTML]
<div id="spreadsheet"></div>
[TS]
let spreadsheet: Spreadsheet = new Spreadsheet({
cssClass: 'e-custom',
sheets: [
{
name: 'Car Sales Report',
ranges: [{ dataSource: (dataSource as any).defaultData }],
},
],
});
spreadsheet.appendTo('#spreadsheet');
[CSS]
/* To disable the collapse icon. */
.e-custom .e-ribbon span.e-drop-icon.e-icons {
display: none;
}
Sample Link: https://stackblitz.com/edit/r3t4ne-pnzz5s?file=index.ts,index.html
Screenshot: