forked from github/plane
style: removed static 'app.plane.so' (#813)
This commit is contained in:
parent
657241c9c1
commit
6de94efc7d
@ -124,7 +124,9 @@ export const CreateWorkspaceForm: React.FC<Props> = ({
|
||||
<div className="flex flex-col items-start justify-center gap-2.5">
|
||||
<span>Workspace URL</span>
|
||||
<div className="flex w-full items-center rounded-md border border-gray-300 px-3">
|
||||
<span className="text-sm text-slate-600">https://app.plane.so/</span>
|
||||
<span className="text-sm text-slate-600">
|
||||
{typeof window !== "undefined" && window.location.origin}/
|
||||
</span>
|
||||
<Input
|
||||
mode="trueTransparent"
|
||||
autoComplete="off"
|
||||
@ -135,7 +137,9 @@ export const CreateWorkspaceForm: React.FC<Props> = ({
|
||||
required: "Workspace URL is required",
|
||||
}}
|
||||
onChange={(e) =>
|
||||
/^[a-zA-Z0-9_-]+$/.test(e.target.value) ? setInvalidSlug(false) : setInvalidSlug(true)
|
||||
/^[a-zA-Z0-9_-]+$/.test(e.target.value)
|
||||
? setInvalidSlug(false)
|
||||
: setInvalidSlug(true)
|
||||
}
|
||||
/>
|
||||
</div>
|
||||
|
@ -238,13 +238,20 @@ const WorkspaceSettings: NextPage = () => {
|
||||
register={register}
|
||||
error={errors.name}
|
||||
className="w-full"
|
||||
value={`app.plane.so/${activeWorkspace.slug}`}
|
||||
value={`${
|
||||
typeof window !== "undefined" &&
|
||||
window.location.origin.replace("http://", "").replace("https://", "")
|
||||
}/${activeWorkspace.slug}`}
|
||||
disabled
|
||||
/>
|
||||
<SecondaryButton
|
||||
className="h-min"
|
||||
onClick={() =>
|
||||
copyTextToClipboard(`https://app.plane.so/${activeWorkspace.slug}`).then(() => {
|
||||
copyTextToClipboard(
|
||||
`${typeof window !== "undefined" && window.location.origin}/${
|
||||
activeWorkspace.slug
|
||||
}`
|
||||
).then(() => {
|
||||
setToastAlert({
|
||||
type: "success",
|
||||
title: "Link Copied!",
|
||||
|
Loading…
Reference in New Issue
Block a user