1
0
mirror of https://github.com/elisspace/AskAssist.git synced 2026-08-29 15:33:47 +00:00

add the options to the top toolbar as a single sentence

This commit is contained in:
Jeremy Dixon
2021-01-18 23:09:36 -06:00
parent a93cce39d1
commit 16903bc37d
3 changed files with 62 additions and 92 deletions

View File

@@ -8,8 +8,7 @@ function appendTool(html){
// fetch the plugin components from the background script...
chrome.runtime.sendMessage({message:{flag:"get", options:[{name:'toolbar', path:"./components/toolbar.html"}, {name:'options', path:"./components/options.html"}]}}, function(res){
//... and append them
document.querySelector('.p-ia__view_header').innerHTML += res.toolbar;
document.querySelector('.c-tabs__tab_menu').innerHTML += res.options;
document.querySelector('.p-workspace__primary_view_contents').innerHTML=res.toolbar+document.querySelector('.p-workspace__primary_view_contents').innerHTML;
//... and their event listeners
document.querySelector('#start-timer').addEventListener('click', function(){
start.style.display = 'none';
@@ -45,7 +44,6 @@ function appendTool(html){
})
var start = document.querySelector('#start-timer');
var stop = document.querySelector('#stop-timer');
//document.querySelector('#options-container').style.display="none"
})
}
@@ -59,9 +57,4 @@ function newQuestion(){
}
function handleInput(e){
console.log("handling input")
console.log(e.target.value);
}
window.addEventListener('load', appendTool);