Full Screen
How to expand the spreadsheet to fit all available space on fullscreen mode.
<script src="https://jspreadsheet.com/v8/jspreadsheet.js"></script>
<script src="https://jsuites.net/v5/jsuites.js"></script>
<link rel="stylesheet" href="https://jspreadsheet.com/v8/jspreadsheet.css" type="text/css" />
<link rel="stylesheet" href="https://jsuites.net/v5/jsuites.css" type="text/css" />
<div id="spreadsheet"></div>
<p><input type="button" value="Set as fullscreen" id="togglebtn"/></p>
<script>
let toggle = function(b) {
worksheets[0].fullscreen(true)
}
// Set the JSS spreadsheet license
jspreadsheet.setLicense('N2QxZTUzNDMwOTBhODNhZjRkNjAwNTlhNGNlZmIyZDQxM2NjMGE4NzZiYzBjODFhZGZmZDc5NzM2N2I2MTBkYTQ3Yzg5NjQ0MmVhMmM0MDI5N2U4N2Q2NGVlYzBmOTkzOTIyYjEwMjdmZDJiMDQ5ZTA4NDAwMzQ2ZGEyYWRiM2IsZXlKamJHbGxiblJKWkNJNklpSXNJbTVoYldVaU9pSktjM0J5WldGa2MyaGxaWFFpTENKa1lYUmxJam94TnpNeU16STVOREl4TENKa2IyMWhhVzRpT2xzaWFuTndjbVZoWkhOb1pXVjBMbU52YlNJc0ltTnZaR1Z6WVc1a1ltOTRMbWx2SWl3aWFuTm9aV3hzTG01bGRDSXNJbU56WWk1aGNIQWlMQ0ozWldJaUxDSnNiMk5oYkdodmMzUWlYU3dpY0d4aGJpSTZJak0wSWl3aWMyTnZjR1VpT2xzaWRqY2lMQ0oyT0NJc0luWTVJaXdpZGpFd0lpd2lkakV4SWl3aVkyaGhjblJ6SWl3aVptOXliWE1pTENKbWIzSnRkV3hoSWl3aWNHRnljMlZ5SWl3aWNtVnVaR1Z5SWl3aVkyOXRiV1Z1ZEhNaUxDSnBiWEJ2Y25SbGNpSXNJbUpoY2lJc0luWmhiR2xrWVhScGIyNXpJaXdpYzJWaGNtTm9JaXdpY0hKcGJuUWlMQ0p6YUdWbGRITWlMQ0pqYkdsbGJuUWlMQ0p6WlhKMlpYSWlMQ0p6YUdGd1pYTWlYU3dpWkdWdGJ5STZkSEoxWlgwPQ==');
// Create the spreadsheet
let worksheets = jspreadsheet(document.getElementById('spreadsheet'), {
toolbar: true,
worksheets: [{
minDimensions: [8,0],
data: [
['Mazda', 2001, 2000, 1],
['Pegeout', 2010, 5000, 1],
['Honda Fit', 2009, 3000, 1],
['Honda CRV', 2010, 6000, 0],
],
}]
});
document.getElementById("togglebtn").onclick = (e) => toggle(e.target)
</script>
</html>