Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/fix-copy-test-url-button-shift.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@clerk/ui': patch
---

Fix layout shift when Copy test URL button enters loading state in `<ConfigureSSO />`
Original file line number Diff line number Diff line change
Expand Up @@ -708,7 +708,6 @@ type CopyTestUrlButtonProps = {
};

const CopyTestUrlButton = ({ onTestRunCreated }: CopyTestUrlButtonProps): JSX.Element => {
const { t } = useLocalizations();
const { user } = useUser();
const card = useCardState();
const { enterpriseConnection } = useConfigureSSO();
Expand Down Expand Up @@ -743,17 +742,22 @@ const CopyTestUrlButton = ({ onTestRunCreated }: CopyTestUrlButtonProps): JSX.El
size='xs'
onClick={createTestRun}
isDisabled={isCreatingTestRun}
isLoading={isCreatingTestRun}
loadingText={t(localizationKeys('configureSSO.testConfigurationStep.testUrl.actionLabel__copy'))}
sx={t => ({
gap: t.space.$1x5,
})}
>
<Icon
icon={hasCopied ? Check : Copy}
size='sm'
colorScheme='neutral'
/>
{isCreatingTestRun ? (
<Spinner
elementDescriptor={descriptors.spinner}
size='xs'
/>
) : (
<Icon
icon={hasCopied ? Check : Copy}
size='sm'
colorScheme='neutral'
/>
)}
<Text
as='span'
localizationKey={localizationKeys('configureSSO.testConfigurationStep.testUrl.actionLabel__copy')}
Expand Down
Loading