I am trying to give dimensions to a Textarea in a modal box.
From here Add content of showModalDialog() to the clipboard Google Script
The HTML is
<textarea id="copy"><?=temp?></textarea>
<button>Copy</button>
<script type="text/javascript">
let t = document.getElementById('copy');
let copy = () => {
t.select();
document.execCommand('copy');
};
/*copy();//try copying without user click */
let bt = document.querySelector('button');
bt.addEventListener('click', copy);
</script>
I can give dimensions to the modal
//Output to Html
var template = HtmlService.createTemplateFromFile('copy');
template.temp = temp;
var htmlOutput = template.evaluate();
htmlOutput.setWidth(610)
htmlOutput.setHeight(500);
SpreadsheetApp.getUi().showModalDialog(htmlOutput, 'OptionList Multiple Selectors');
}
I am trying to get the dimensions of the Modal and the Textarea to be the same as it is now the textarea is about 20 x 50.