浏览代码

Better position the help tooltip; make sure it appears on top

tags/v0.1.0
Fen Dweller 5 年前
父节点
当前提交
286e5bf97a
找不到此签名对应的密钥 GPG 密钥 ID: E80B35A6F11C3656
共有 3 个文件被更改,包括 9 次插入6 次删除
  1. +5
    -1
      gorge.css
  2. +3
    -4
      gorge.html
  3. +1
    -1
      gorge.js

+ 5
- 1
gorge.css 查看文件

@@ -826,12 +826,16 @@ div::-webkit-scrollbar-corner {
} }


.has-help { .has-help {
} }


#help-tooltip { #help-tooltip {
position: fixed;
color: #888; color: #888;
background: #000; background: #000;
max-width: 400px; max-width: 400px;
font-size: 16pt; font-size: 16pt;
z-index: 1;
left: 0%;
top: 0%;
} }

+ 3
- 4
gorge.html 查看文件

@@ -42,16 +42,15 @@
<div id="resource-list"></div> <div id="resource-list"></div>
<div id="productivity"></div> <div id="productivity"></div>
<button id="tasty-micro"></button> <button id="tasty-micro"></button>
<div id="help-tooltip">
<div id="help-tooltip-help"></div>
</div>
<div id="powerup-list"></div> <div id="powerup-list"></div>
<div id="powerup-tooltip"> <div id="powerup-tooltip">
<div id="powerup-tooltip-name"></div> <div id="powerup-tooltip-name"></div>
<div id="powerup-tooltip-desc"></div> <div id="powerup-tooltip-desc"></div>
</div> </div>
</div> </div>

<div id="help-tooltip">
<div id="help-tooltip-help"></div>
</div>
<div id="upgrades-area"> <div id="upgrades-area">
<div id="upgrades" class="title switcher-button">Upgrades</div> <div id="upgrades" class="title switcher-button">Upgrades</div>
<div id="upgrade-tooltip"> <div id="upgrade-tooltip">


+ 1
- 1
gorge.js 查看文件

@@ -1399,7 +1399,7 @@ function helpTooltip(element, event) {


fillTooltip("help", "help", text); fillTooltip("help", "help", text);


let xPos = tooltip.parentElement.getBoundingClientRect().x + 450;
let xPos = event.clientX + 100;


// wow browsers are bad // wow browsers are bad




正在加载...
取消
保存