We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents d787c9f + 8c2e60d commit 2bfc145Copy full SHA for 2bfc145
app/assets/javascripts/chat.coffee
@@ -144,9 +144,9 @@ class Chat
144
.css(display: "none", position: "absolute")
145
.append("<img src=\"#{@totoz_url}#{totozName}\"/>")
146
@totoz.append totoz
147
- offset = $(event.target).offset()
148
- [x, y] = [offset.left, offset.top]
149
- totoz.css "z-index": "15", display: "block", top: y + 20, left: x + 20
+ position = $(event.target).position()
+ [x, y] = [position.left, position.top + event.target.offsetHeight]
+ totoz.css "z-index": "15", display: "block", top: y + 5, left: x + 5
150
151
destroyTotoz: (event) =>
152
totozId = encodeURIComponent(event.target.getAttribute("data-totoz-name")).replace(/[%']/g, "")
0 commit comments