kopia lustrzana https://github.com/bugout-dev/moonstream
do not trap focus on modal window
rodzic
a65f108d2e
commit
03a20ffb00
|
@ -65,7 +65,7 @@ const Tokens = () => {
|
||||||
</Center>
|
</Center>
|
||||||
) : (
|
) : (
|
||||||
<ScaleFade in>
|
<ScaleFade in>
|
||||||
<Modal isOpen={isOpen} onClose={onClose}>
|
<Modal isOpen={isOpen} onClose={onClose} size="lg" trapFocus={false}>
|
||||||
<ModalOverlay />
|
<ModalOverlay />
|
||||||
<ModalContent>
|
<ModalContent>
|
||||||
<ModalHeader>New API access token</ModalHeader>
|
<ModalHeader>New API access token</ModalHeader>
|
||||||
|
|
|
@ -8,7 +8,7 @@ import {
|
||||||
Stack,
|
Stack,
|
||||||
Button,
|
Button,
|
||||||
Input,
|
Input,
|
||||||
Text,
|
chakra,
|
||||||
} from "@chakra-ui/react";
|
} from "@chakra-ui/react";
|
||||||
import { useEffect, useState, useRef } from "react";
|
import { useEffect, useState, useRef } from "react";
|
||||||
import { Icon } from "../../src/Theme";
|
import { Icon } from "../../src/Theme";
|
||||||
|
@ -61,7 +61,7 @@ const TokenRequest = ({ setNewToken, onClose }) => {
|
||||||
<form onSubmit={handleSubmit(createToken.mutate)} style={formStyle}>
|
<form onSubmit={handleSubmit(createToken.mutate)} style={formStyle}>
|
||||||
<Stack direction="column" spacing={4} w="100%">
|
<Stack direction="column" spacing={4} w="100%">
|
||||||
<Stack direction="column" spacing={1}>
|
<Stack direction="column" spacing={1}>
|
||||||
<Text fontSize="sm">API key label</Text>
|
<chakra.label for="pwd">API key label:</chakra.label>
|
||||||
<Input
|
<Input
|
||||||
w="100%"
|
w="100%"
|
||||||
ref={register}
|
ref={register}
|
||||||
|
@ -71,18 +71,19 @@ const TokenRequest = ({ setNewToken, onClose }) => {
|
||||||
/>
|
/>
|
||||||
</Stack>
|
</Stack>
|
||||||
<Stack direction="column" spacing={1}>
|
<Stack direction="column" spacing={1}>
|
||||||
<Text fontSize="sm">Your password</Text>
|
<chakra.label for="pwd">Password:</chakra.label>
|
||||||
<FormControl isInvalid={errors.password}>
|
<FormControl isInvalid={errors.password}>
|
||||||
<InputGroup minWidth="300px">
|
<InputGroup minWidth="300px">
|
||||||
<InputLeftElement onClick={togglePassword}>
|
<InputLeftElement onClick={togglePassword}>
|
||||||
<Icon icon="password" />
|
<Icon icon="password" />
|
||||||
</InputLeftElement>
|
</InputLeftElement>
|
||||||
|
|
||||||
<Input
|
<Input
|
||||||
|
id="pwd"
|
||||||
colorScheme="blue"
|
colorScheme="blue"
|
||||||
variant="filled"
|
variant="filled"
|
||||||
isDisabled={createToken.isLoading}
|
isDisabled={createToken.isLoading}
|
||||||
autoComplete="on"
|
placeholder="This action requires your password to confirm"
|
||||||
placeholder="Your Bugout password"
|
|
||||||
name="password"
|
name="password"
|
||||||
type={showPassword}
|
type={showPassword}
|
||||||
ref={(e) => {
|
ref={(e) => {
|
||||||
|
|
Ładowanie…
Reference in New Issue