mirror of
https://gh-proxy.org/https://github.com/klinsmaya/SQLBot.git
synced 2026-11-08 01:06:59 +08:00
fix(assistant): High-resolution icon for the assistant
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
;(function () {
|
||||
; (function () {
|
||||
window.sqlbot_assistant_handler = window.sqlbot_assistant_handler || {}
|
||||
const defaultData = {
|
||||
id: '1',
|
||||
@@ -170,6 +170,13 @@
|
||||
chat_button_img = root.querySelector('.sqlbot-assistant-chat-button > img')
|
||||
}
|
||||
chat_button_img.style.display = 'block'
|
||||
function resizeImg() {
|
||||
const rate = window.outerWidth / window.innerWidth;
|
||||
chat_button_img.style.width = `${30 * (1 / rate)}px`;
|
||||
chat_button_img.style.height = `${30 * (1 / rate)}px`;
|
||||
}
|
||||
resizeImg()
|
||||
window.addEventListener('resize', resizeImg);
|
||||
// 对话框元素
|
||||
const chat_container = root.querySelector('#sqlbot-assistant-chat-container')
|
||||
// 引导层
|
||||
|
||||
Reference in New Issue
Block a user