mirror of
https://github.com/owncast/owncast.git
synced 2024-10-10 19:16:02 +00:00
Replace search button on auth modals. Closes #2377
This commit is contained in:
parent
b5e504246f
commit
49b4300e2e
@ -1,5 +1,6 @@
|
||||
import { Alert, Button, Input, Space, Spin, Collapse } from 'antd';
|
||||
import React, { FC, useState } from 'react';
|
||||
import { CheckCircleOutlined } from '@ant-design/icons';
|
||||
import styles from './FediAuthModal.module.scss';
|
||||
import { validateAccount } from '../../../utils/validators';
|
||||
|
||||
@ -140,6 +141,11 @@ export const FediAuthModal: FC<FediAuthModalProps> = ({
|
||||
placeholder="youraccount@yourserver.com"
|
||||
status={!valid && account.length > 0 ? 'error' : undefined}
|
||||
onSearch={submitAccountPressed}
|
||||
enterButton={
|
||||
<Button type={valid ? 'primary' : 'default'} disabled={!valid || account.length === 0}>
|
||||
<CheckCircleOutlined />
|
||||
</Button>
|
||||
}
|
||||
/>
|
||||
</>
|
||||
);
|
||||
|
@ -1,4 +1,5 @@
|
||||
import { Alert, Input, Space, Spin, Collapse, Typography } from 'antd';
|
||||
import { CheckCircleOutlined } from '@ant-design/icons';
|
||||
import { Alert, Input, Space, Spin, Collapse, Typography, Button } from 'antd';
|
||||
import React, { FC, useState } from 'react';
|
||||
import isValidURL from '../../../utils/urls';
|
||||
|
||||
@ -125,6 +126,11 @@ export const IndieAuthModal: FC<IndieAuthModalProps> = ({
|
||||
placeholder="yoursite.com"
|
||||
status={!valid && host.length > 0 ? 'error' : undefined}
|
||||
onSearch={submitButtonPressed}
|
||||
enterButton={
|
||||
<Button type={valid ? 'primary' : 'default'} disabled={!valid || host.length === 0}>
|
||||
<CheckCircleOutlined />
|
||||
</Button>
|
||||
}
|
||||
/>
|
||||
|
||||
<Collapse ghost>
|
||||
|
Loading…
x
Reference in New Issue
Block a user