mirror of
https://github.com/nonebot/nonebot2.git
synced 2024-11-24 00:55:07 +08:00
🐛 fix modal hidden
This commit is contained in:
parent
338c41abd5
commit
620938c26c
@ -1,22 +1,20 @@
|
||||
from sys import intern
|
||||
|
||||
# used by Matcher
|
||||
RECEIVE_KEY = intern("_receive_{id}")
|
||||
LAST_RECEIVE_KEY = intern("_last_receive")
|
||||
ARG_KEY = intern("{key}")
|
||||
REJECT_TARGET = intern("_current_target")
|
||||
REJECT_CACHE_TARGET = intern("_next_target")
|
||||
RECEIVE_KEY = "_receive_{id}"
|
||||
LAST_RECEIVE_KEY = "_last_receive"
|
||||
ARG_KEY = "{key}"
|
||||
REJECT_TARGET = "_current_target"
|
||||
REJECT_CACHE_TARGET = "_next_target"
|
||||
|
||||
# used by Rule
|
||||
PREFIX_KEY = intern("_prefix")
|
||||
PREFIX_KEY = "_prefix"
|
||||
|
||||
CMD_KEY = intern("command")
|
||||
RAW_CMD_KEY = intern("raw_command")
|
||||
CMD_ARG_KEY = intern("command_arg")
|
||||
CMD_KEY = "command"
|
||||
RAW_CMD_KEY = "raw_command"
|
||||
CMD_ARG_KEY = "command_arg"
|
||||
|
||||
SHELL_ARGS = intern("_args")
|
||||
SHELL_ARGV = intern("_argv")
|
||||
SHELL_ARGS = "_args"
|
||||
SHELL_ARGV = "_argv"
|
||||
|
||||
REGEX_MATCHED = intern("_matched")
|
||||
REGEX_GROUP = intern("_matched_groups")
|
||||
REGEX_DICT = intern("_matched_dict")
|
||||
REGEX_MATCHED = "_matched"
|
||||
REGEX_GROUP = "_matched_groups"
|
||||
REGEX_DICT = "_matched_dict"
|
||||
|
@ -15,11 +15,8 @@ export default function Modal({
|
||||
{/* overlay */}
|
||||
<div
|
||||
className={clsx(
|
||||
"fixed top-0 bottom-0 left-0 right-0 flex items-center justify-center transition z-[200]",
|
||||
{
|
||||
hidden: !active,
|
||||
"pointer-events-auto": active,
|
||||
}
|
||||
"fixed top-0 bottom-0 left-0 right-0 flex items-center justify-center transition z-[200] pointer-events-auto",
|
||||
{ "!hidden": !active }
|
||||
)}
|
||||
onClick={() => setActive(false)}
|
||||
>
|
||||
@ -28,11 +25,12 @@ export default function Modal({
|
||||
{/* modal */}
|
||||
<div
|
||||
className={clsx(
|
||||
"fixed top-0 left-0 flex items-center justify-center h-full w-full transition z-[201] pointer-events-none",
|
||||
{ hidden: !active }
|
||||
"fixed top-0 left-0 flex items-center justify-center h-full w-full z-[201] pointer-events-none",
|
||||
{ "!hidden": !active }
|
||||
)}
|
||||
tabIndex={0}
|
||||
>
|
||||
<div className="w-full max-w-[600px] max-h-[90%] overflow-y-auto rounded shadow-lg m-6 origin-center transition z-[inherit] pointer-events-auto thin-scrollbar">
|
||||
<div className="w-full max-w-[600px] max-h-[90%] overflow-y-auto rounded shadow-lg m-6 z-[inherit] pointer-events-auto thin-scrollbar">
|
||||
<div className="bg-light-nonepress-100 dark:bg-dark-nonepress-100">
|
||||
{children}
|
||||
</div>
|
||||
|
Loading…
Reference in New Issue
Block a user