PageSourceSearch

https://roboteach.us/menu.js

js roboteach.us collected 2026-10-07 18:53:25 UTC 4,198 bytes, 77 lines download raw bytes

1// menu.js
2;(function(){
3  const style=document.createElement('style')
4  style.textContent=`
5    .dropdown{position:fixed;top:10px;left:10px;z-index:99999}
6    .dropdown-button{padding:10px 12px;cursor:pointer;border:1px solid #ccc;background:#c0c0c0;font-weight:bold}
7    .dropdown-content{display:none;position:absolute;background:#fff;min-width:160px;box-shadow:0 8px 16px rgba(0,0,0,0.2);z-index:100000}
8    .dropdown-content a{display:block;padding:2px 16px;color:#333;text-decoration:none;font-weight:bold}
9    .dropdown-content a:hover{background:#f1f1f1}
10    .show{display:block}
11  `
12  document.head.appendChild(style)
13
14  const dropdown=document.createElement('div'); dropdown.className='dropdown'
15  const btn=document.createElement('div'); btn.className='dropdown-button'; btn.textContent='Menu'
16  const menu=document.createElement('div'); menu.className='dropdown-content'
17  const openKate=()=>{
18    const kateOpener=document.getElementById('rtKateWidgetLauncher') || document.querySelector('[data-rt-kate-open]')
19    if(kateOpener){
20      kateOpener.click()
21      return
22    }
23    location.href='/index.php?kate=1'
24  }
25
26  const items=[
27    { label:'Home',             action:()=> location.href='/index.php' },
28    { label:'Create Lesson',    action:()=>{
29        const onIndex=/(\/|index\.php)$/.test(location.pathname)
30        if(!onIndex) location.href='index.php?menuAction=create-lesson'
31        else document.querySelector('button[data-action="create-lesson"]').click()
32      }
33    },
34    { label:'Search Lessons', action:()=> location.href='/lessons.php' },
35    { label:'Free Textbooks', action:()=> location.href='/textbook' },
36    { label:'Paid Textbooks', action:()=> location.href='https://click.linksynergy.com/fs-bin/click?id=%2fNaKtUZpj3w&offerid=1338946.7&type=3&subid=0' },
37    { label:'Interactive Tutor', action:()=> location.href='/tutor.php' },
38    { label:'Class Monitor', action:()=> location.href='/tattle.php' },
39    { label:'Puppet',       action:()=> location.href='/puppet.php' },
40    { label:'Planetarium', action:()=> location.href='/planetarium' },
41    { label:'Cash Handling', action:()=> location.href='/cashhandling' },
42    { label:'Math Practice', action:()=> location.href='/math.php' },
43    { label:'Crosswords', action:()=> location.href='/crossword.php' },
44    { label:'User Guide',       action:()=> location.href='/help.php' },
45    { label:'Share',       action:()=> location.href='/recommend.php' },
46    { label:'Newsletter',       action:()=> location.href='/newsletter' },
47    { label:'Kate',        action:openKate }
48  ]
49
50  items.forEach(i=>{
51    const link=document.createElement('a')
52    link.href='javascript:void(0)'
53    link.textContent=i.label
54    link.addEventListener('click',()=>{
55      menu.classList.remove('show')
56      i.action()
57    })
58    menu.appendChild(link)
59  })
60
61  dropdown.appendChild(btn)
62  dropdown.appendChild(menu)
63  btn.addEventListener('click',()=> menu.classList.toggle('show'))
64  document.addEventListener('click',e=>{ if(!dropdown.contains(e.target)) menu.classList.remove('show') })
65  document.body.insertBefore(dropdown,document.body.firstChild)
66})()
67  var _rakuten_automate = {
68    u1: "",
69    snippetURL: "https://automate-frontend.linksynergy.com/minified_logic.js",
70    automateURL: "https://automate.linksynergy.com",
71    widgetKey: "lyVFLfGWIRU8jH7dIJrONAEtAeJwXlt0",
72    aelJS: null,
73    useDefaultAEL: false,
74    loaded: false,
75    events: []
76  };
77  var ael=window.addEventListener;window.addEventListener=function(a,b,c,d){"click"!==a&&_rakuten_automate.useDefaultAEL?ael(a,b,c):_rakuten_automate.events.push({type:a,handler:b,capture:c,rakuten:d})};_rakuten_automate.links={};var httpRequest=new XMLHttpRequest;httpRequest.open("GET",_rakuten_automate.snippetURL,!0);httpRequest.timeout=5E3;httpRequest.ontimeout=function(){if(!_rakuten_automate.loaded){for(i=0;i<_rakuten_automate.events.length;i++){var a=_rakuten_automate.events[i];ael(a.type,a.handler,a.capture)}_rakuten_automate.useDefaultAEL=!0}};httpRequest.onreadystatechange=function(){httpRequest.readyState===XMLHttpRequest.DONE&&200===httpRequest.status&&(eval(httpRequest.responseText),_rakuten_automate.run(ael))};httpRequest.send(null);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.