on master help sign in
Underline links
commite83e5bec3cafb0fcfdec34ea9f3f62f580188aef authorDevine Lu Linvega <aliceffekt@gmail.com> dateMon 29 Jul 2019, 10:01 (7 years ago) parent6c3d783
2 files changed+5−3
links/main.css+3−2 scripts/wiki.js+2−1
links/main.css+3−2
@@ -4,7 +4,7 @@ body { background:#f4f4f4; padding:0px; margin:0px; }
44body > div { display:block; background: #111;min-height: calc(100vh - 60px);width: calc(100vw - 60px);margin: 15px;color: #333;padding: 15px;font-family:'input_mono_regular', 'Monospaced','Courier New',courier;font-size:11px; position: relative; border-radius: 2px; color:white; overflow: hidden;}
55body div ul { max-width: 800px; border-bottom: 2px solid white;padding-bottom: 15px;margin-bottom:15px; overflow: hidden;}
66body div p { display:block; padding:0px 5px; line-height: 20px; max-width: 600px}
7−body div p a { text-decoration: underline;}
7+body div p a { text-decoration: underline; cursor: pointer;}
88body div p a:hover { text-decoration: underline; }
99body b { font-weight: normal; font-family: 'input_mono_medium' }
1010body div p.readme { max-width:500px; }
@@ -80,9 +80,10 @@ body #portal ul li a:hover { text-decoration: underline; }
8080/* Wiki */
8181
8282body #wiki #entry { max-width: calc(100% - 230px); margin-bottom: 30px }
83+body #wiki #entry a { text-decoration: underline; }
8384body #wiki ul.term { border-bottom: 0px; margin-bottom: 0px; padding-bottom: 0px}
8485body #wiki ul.term li.name { margin-bottom: 5px }
85−body #wiki ul.term li a.author { color:#555; }
86+body #wiki ul.term li a.author { color:#555; text-decoration: none !important; }
8687
8788
8889
scripts/wiki.js+2−1
@@ -50,7 +50,8 @@ function Wiki (sites) {
5050 this._entry.innerHTML = html
5151 }
5252 } else {
53− this._entry.innerHTML = `Click a /topic to get started, or try a <a onclick='wiki.go("${this.random()}")'>random page</a>.`
53+ const random = this.random()
54+ this._entry.innerHTML = `Click a /topic to get started, or try a <a href='#${random.toUrl()}' onclick='wiki.go("${random}")'>random page</a>.`
5455 }
5556 // Sidebar
5657 this._categories.innerHTML = Object.keys(this.categories).reduce((acc, id) => { return this.categories[id].length > 5 ? `${acc}<li onclick='wiki.go("${id}")' class='${wiki.at(id) ? 'selected' : ''}'>${id.substr(0, 20)} <span class='right'>${this.categories[id].length}</span></li>` : acc }, '')