fix: Copy button disabled while it's value is null (#1328)

Co-authored-by: ShubhamPalriwala <spalriwalau@gmail.com>
This commit is contained in:
Shyam Raghuwanshi
2023-10-20 12:46:42 +05:30
committed by GitHub
parent 8677025ba4
commit ba3b3ef3d2
2 changed files with 3 additions and 1 deletions

View File

@@ -2,4 +2,4 @@ NEXT_PUBLIC_FORMBRICKS_API_HOST=http://localhost:3000
NEXT_PUBLIC_FORMBRICKS_ENVIRONMENT_ID=YOUR_ENVIRONMENT_ID
# Copy the environment ID for the URL of your Formbricks App and
# paste it above to connect your Formbricks App with the Demo App.
# paste it above to connect your Formbricks App with the Demo App.

View File

@@ -116,6 +116,7 @@ export default function UrlShortenerModal({ open, setOpen, surveyBaseUrl }: UrlS
onBlur={handleUrlValidation}
/>
<Button
disabled={watch("url") === "" ? true : false}
variant="darkCTA"
size="sm"
className="col-span-1 text-center"
@@ -139,6 +140,7 @@ export default function UrlShortenerModal({ open, setOpen, surveyBaseUrl }: UrlS
{shortUrl}
</span>
<Button
disabled={shortUrl === "" ? true : false}
variant="secondary"
size="sm"
className="col-span-1 justify-center"