feat: make the floating selectionTools follow the scrolling, while the result window remains fixed (#40)

This commit is contained in:
josc146
2023-03-21 16:33:48 +08:00
parent 1adf4714ad
commit 75b23174bf
5 changed files with 17 additions and 15 deletions
+4
View File
@@ -0,0 +1,4 @@
export function getClientPosition(e) {
const rect = e.getBoundingClientRect()
return { x: rect.left, y: rect.top }
}
+1
View File
@@ -2,6 +2,7 @@ export * from './create-element-at-position'
export * from './crop-text'
export * from './ends-with-question-mark'
export * from './fetch-sse'
export * from './get-client-position'
export * from './get-conversation-pairs'
export * from './get-possible-element-by-query-selector'
export * from './init-session'