mirror of
https://github.com/KimigaiiWuyi/GenshinUID.git
synced 2025-05-07 20:45:49 +08:00
🐛 为按钮添加前缀 (#679)
This commit is contained in:
parent
a800644f8b
commit
6884266b21
1
.vscode/settings.json
vendored
1
.vscode/settings.json
vendored
@ -18,4 +18,5 @@
|
||||
"basedpyright.analysis.extraPaths": [
|
||||
"${workspaceFolder}/../../../"
|
||||
],
|
||||
"python.analysis.typeCheckingMode": "off",
|
||||
}
|
@ -3,11 +3,11 @@ import re
|
||||
from gsuid_core.sv import SV
|
||||
from gsuid_core.bot import Bot
|
||||
from gsuid_core.models import Event
|
||||
from gsuid_core.message_models import Button
|
||||
from gsuid_core.utils.error_reply import UID_HINT
|
||||
|
||||
from ..utils.convert import get_uid
|
||||
from .draw_abyss_card import draw_abyss_img
|
||||
from ..utils.message import GButton as Button
|
||||
|
||||
sv_abyss = SV('查询深渊')
|
||||
|
||||
|
@ -27,7 +27,6 @@ def cache(ttl=datetime.timedelta(hours=1), **kwargs):
|
||||
|
||||
@functools.wraps(func)
|
||||
async def wrapped(*args, **kw):
|
||||
nonlocal cache_data
|
||||
bound = inspect.signature(func).bind(*args, **kw)
|
||||
bound.apply_defaults()
|
||||
ins_key = '|'.join(
|
||||
|
@ -1,10 +1,10 @@
|
||||
from gsuid_core.sv import SV
|
||||
from gsuid_core.bot import Bot
|
||||
from gsuid_core.models import Event
|
||||
from gsuid_core.message_models import Button
|
||||
from gsuid_core.utils.error_reply import UID_HINT
|
||||
|
||||
from ..utils.convert import get_uid
|
||||
from ..utils.message import GButton as Button
|
||||
from .draw_new_collection_card import draw_explore
|
||||
from .draw_collection_card import draw_explora_img, draw_collection_img
|
||||
|
||||
|
@ -8,7 +8,6 @@ from gsuid_core.sv import SV
|
||||
from gsuid_core.bot import Bot
|
||||
from gsuid_core.models import Event
|
||||
from gsuid_core.logger import logger
|
||||
from gsuid_core.message_models import Button
|
||||
from gsuid_core.utils.error_reply import UID_HINT
|
||||
|
||||
from .to_data import switch_api
|
||||
@ -20,6 +19,7 @@ from .to_data_by_mys import mys_to_card
|
||||
from .draw_artifacts_lib import draw_lib
|
||||
from .draw_rank_list import draw_rank_img
|
||||
from ..utils.image.convert import convert_img
|
||||
from ..utils.message import GButton as Button
|
||||
from ..utils.map.GS_MAP_PATH import alias_data
|
||||
from .draw_arti_rank import draw_arti_rank_img
|
||||
from .draw_char_info import draw_all_char_list
|
||||
|
@ -3,10 +3,10 @@ from pathlib import Path
|
||||
from gsuid_core.sv import SV
|
||||
from gsuid_core.bot import Bot
|
||||
from gsuid_core.models import Event
|
||||
from gsuid_core.message_models import Button
|
||||
|
||||
from ..version import Genshin_version
|
||||
from ..utils.image.convert import convert_img
|
||||
from ..utils.message import GButton as Button
|
||||
|
||||
PRIMOGEMS_DATA_PATH = Path(__file__).parent / 'primogems_data'
|
||||
IMG_PATH = Path(__file__).parent / 'img_data'
|
||||
|
@ -2,9 +2,9 @@ from gsuid_core.sv import SV
|
||||
from gsuid_core.bot import Bot
|
||||
from gsuid_core.models import Event
|
||||
from gsuid_core.aps import scheduler
|
||||
from gsuid_core.message_models import Button
|
||||
|
||||
from ..utils.image.convert import convert_img
|
||||
from ..utils.message import GButton as Button
|
||||
from .draw_event_img import get_event_img, get_all_event_img
|
||||
|
||||
sv_event_list = SV('活动列表')
|
||||
|
@ -2,12 +2,12 @@ from gsuid_core.sv import SV
|
||||
from gsuid_core.bot import Bot
|
||||
from gsuid_core.models import Event
|
||||
from gsuid_core.logger import logger
|
||||
from gsuid_core.message_models import Button
|
||||
from gsuid_core.segment import MessageSegment
|
||||
from gsuid_core.utils.error_reply import UID_HINT
|
||||
from gsuid_core.utils.database.models import GsBind
|
||||
|
||||
from ..utils.convert import get_uid
|
||||
from ..utils.message import GButton as Button
|
||||
from .draw_gachalogs import draw_gachalogs_img
|
||||
from .get_gachalogs import save_gachalogs, get_full_gachalog
|
||||
from .export_and_import import export_gachalogs, import_gachalogs
|
||||
|
@ -2,12 +2,12 @@ from gsuid_core.sv import SV
|
||||
from gsuid_core.bot import Bot
|
||||
from gsuid_core.models import Event
|
||||
from gsuid_core.logger import logger
|
||||
from gsuid_core.message_models import Button
|
||||
from gsuid_core.utils.error_reply import UID_HINT
|
||||
|
||||
from ..utils.convert import get_uid
|
||||
from .draw_gcgdesk import draw_deck_img
|
||||
from .draw_gcginfo import draw_gcg_info
|
||||
from ..utils.message import GButton as Button
|
||||
|
||||
sv_gcg = SV('查询七圣')
|
||||
|
||||
|
@ -5,7 +5,6 @@ from gsuid_core.sv import SV
|
||||
from gsuid_core.bot import Bot
|
||||
from gsuid_core.models import Event
|
||||
from gsuid_core.logger import logger
|
||||
from gsuid_core.message_models import Button
|
||||
from gsuid_core.segment import MessageSegment
|
||||
|
||||
from .get_guide import get_gs_guide
|
||||
@ -13,6 +12,7 @@ from ..version import Genshin_version
|
||||
|
||||
# from .get_abyss_data import get_review
|
||||
from ..utils.image.convert import convert_img
|
||||
from ..utils.message import GButton as Button
|
||||
from .get_new_abyss_data import get_review_data
|
||||
from ..utils.resource.RESOURCE_PATH import REF_PATH
|
||||
from .get_bbs_post_guide import get_material_way_post
|
||||
|
@ -1,12 +1,12 @@
|
||||
from gsuid_core.sv import SV
|
||||
from gsuid_core.bot import Bot
|
||||
from gsuid_core.models import Event
|
||||
from gsuid_core.message_models import Button
|
||||
from gsuid_core.segment import MessageSegment
|
||||
from gsuid_core.utils.database.models import GsBind
|
||||
|
||||
from .get_ck_help_msg import get_ck_help
|
||||
from ..utils.message import send_diff_msg
|
||||
from ..utils.message import GButton as Button
|
||||
|
||||
sv_user_info = SV('用户信息')
|
||||
sv_user_help = SV('绑定帮助')
|
||||
|
@ -1,4 +1,4 @@
|
||||
from gsuid_core.message_models import Button
|
||||
from ..utils.message import GButton as Button
|
||||
|
||||
a = Button('🔍查询探索', '查询探索')
|
||||
b = Button('🔍查询收集', '查询收集')
|
||||
|
@ -2,6 +2,13 @@ from typing import Any, Dict, List, Union, Optional
|
||||
|
||||
from gsuid_core.bot import Bot
|
||||
from gsuid_core.message_models import Button
|
||||
from gsuid_core.sv import get_plugin_available_prefix
|
||||
|
||||
PREFIX = get_plugin_available_prefix('GenshinUID')
|
||||
|
||||
|
||||
class GButton(Button):
|
||||
prefix = PREFIX
|
||||
|
||||
|
||||
async def send_diff_msg(
|
||||
|
Loading…
x
Reference in New Issue
Block a user