elements: fix linkDownloadKp
This commit is contained in:
parent
c9523328da
commit
f4acf8c316
@ -504,7 +504,7 @@ const props: Partial<ElementsProps> = {
|
||||
width: '100%',
|
||||
},
|
||||
},
|
||||
linkDownloadKp: { children: 'Скачать КП', icon: <DownloadOutlined />, target: '_blank' },
|
||||
linkDownloadKp: { children: 'Скачать КП', icon: <DownloadOutlined /> },
|
||||
tbxMileage: {
|
||||
min: 0,
|
||||
step: 100,
|
||||
|
||||
@ -1,17 +1,9 @@
|
||||
import type { ButtonProps } from 'antd';
|
||||
import { Button as AntButton } from 'antd';
|
||||
|
||||
export function Link({ href, ...props }: ButtonProps) {
|
||||
export function Link({ ...props }: ButtonProps) {
|
||||
return (
|
||||
<AntButton
|
||||
rel="noopener"
|
||||
target="_blank"
|
||||
type="link"
|
||||
onClick={() => {
|
||||
window.open(href, '_blank')?.focus();
|
||||
}}
|
||||
{...props}
|
||||
>
|
||||
<AntButton rel="noopener" target="_blank" type="link" {...props}>
|
||||
{props.children}
|
||||
</AntButton>
|
||||
);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user