fix(ui): allow to copy api url even in invalid state
This commit is contained in:
@@ -36,6 +36,7 @@ const apiUrl = computed((previous) => {
|
|||||||
|
|
||||||
return `${baseApiUrl}?${params}`;
|
return `${baseApiUrl}?${params}`;
|
||||||
});
|
});
|
||||||
|
const isValidApiUrl = computed(() => !!apiUrl.value);
|
||||||
|
|
||||||
const { icon: copyUrlIcon, copy: copyUrl } = useCopyable(apiUrl);
|
const { icon: copyUrlIcon, copy: copyUrl } = useCopyable(apiUrl);
|
||||||
|
|
||||||
@@ -170,7 +171,7 @@ const {
|
|||||||
/>
|
/>
|
||||||
<UButton
|
<UButton
|
||||||
color="gray"
|
color="gray"
|
||||||
:disabled="!isValidState"
|
:disabled="!isValidApiUrl"
|
||||||
:icon="copyUrlIcon"
|
:icon="copyUrlIcon"
|
||||||
@click="copyUrl"
|
@click="copyUrl"
|
||||||
/>
|
/>
|
||||||
|
|||||||
Reference in New Issue
Block a user