Skip to content

Commit 8219888

Browse files
authored
Merge pull request #667 from AnnMarieW/update-copy-button
Copy Buttons -change timeout default to 1000
2 parents d3da52c + 25cc904 commit 8219888

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

src/ts/components/core/button/CopyButton.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import { getTargetText } from '../../../utils/dash3';
1515
interface Props extends DashBaseProps, BoxProps, StylesApiProps {
1616
/** Value to be copied to clipboard */
1717
value: string;
18-
/** Copied status timeout in ms, `500` by default */
18+
/** Copied status timeout in ms, `1000` by default */
1919
timeout?: number;
2020
/** Controls button `height`, `font-size` and horizontal `padding`, `'sm'` by default */
2121
size?: MantineSize | `compact-${MantineSize}` | (string & {});
@@ -51,7 +51,7 @@ interface Props extends DashBaseProps, BoxProps, StylesApiProps {
5151
/** CopyButton - Button component with copy to clipboard functionality */
5252
const CopyButton = ({
5353
value = '',
54-
timeout = 500,
54+
timeout = 1000,
5555
triggerCopy = false,
5656
children,
5757
copiedChildren,

src/ts/components/core/button/CustomCopyButton.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { resolveProp } from '../../../utils/prop-functions';
88
interface Props {
99
/** Value to be copied to clipboard */
1010
value: string;
11-
/** Copied status timeout in ms, `500` by default */
11+
/** Copied status timeout in ms, `1000` by default */
1212
timeout?: number;
1313
/** Function that receives {copied, copy} and returns a component See https://www.dash-mantine-components.com/functions-as-props*/
1414
children?: any;
@@ -21,7 +21,7 @@ interface Props {
2121
/** CustomCopyButton - custom component with copy to clipboard functionality */
2222
const CustomCopyButton = ({
2323
value,
24-
timeout = 500,
24+
timeout = 1000,
2525
children,
2626
setProps
2727
}: Props) => {

0 commit comments

Comments
 (0)