我正在尝试使用 Google Apps 脚本实现交互式页面。我已经在 UI 侧边栏中成功打开了一个文档,但是侧边栏的尺寸使其难以使用:
如何使嵌入式侧边栏页面更具吸引力/更易于使用?
我的谷歌文档在这里:https ://docs.google.com/document/d/17AtHwUSQdci-lh7BDvXeELcpZdXr27AryHlfagRR4Hg/edit
var TITLE = 'Sidebar Title';
//Here is the code.gs code:
function onOpen() {
var ui = DocumentApp.getUi();
ui.createMenu('==Sidebar==')
.addItem('Show Document','SideBar3')
.addToUi();
};
function SideBar3()
{
var ui = HtmlService.createHtmlOutputFromFile('ModeLessDialog').setTitle('Handler Communications');
ui.setWidth(800)
DocumentApp.getUi().showSidebar(ui);
}
//Here is the HTML file. I called it ModeLessDialog.html
<!DOCTYPE html>
<html>
<head>
<base target="_top">
</head>
<body>
<iframe src="https://docs.google.com/document/d/1yb7knN941rdS-6okHQu_ZkvkgIaqXUIMioSAru9fzK4/" height="1000" width="90%"></iframe>
</body>
</html>