feat: minor bug fixes and text changes

This commit is contained in:
Akhil Mohan
2024-03-12 21:49:33 +05:30
parent f1f18e81cd
commit 4152b3a524
11 changed files with 51 additions and 40 deletions
@@ -78,18 +78,26 @@ export const ProjectNameChangeSection = () => {
</CopyButton>
</div>
</div>
<div className="max-w-md">
<Controller
defaultValue=""
render={({ field, fieldState: { error } }) => (
<FormControl isError={Boolean(error)} errorText={error?.message}>
<Input placeholder="Project name" {...field} className="bg-mineshaft-800" />
</FormControl>
<ProjectPermissionCan I={ProjectPermissionActions.Edit} a={ProjectPermissionSub.Workspace}>
{(isAllowed) => (
<Controller
defaultValue=""
render={({ field, fieldState: { error } }) => (
<FormControl isError={Boolean(error)} errorText={error?.message}>
<Input
placeholder="Project name"
{...field}
className="bg-mineshaft-800"
isDisabled={!isAllowed}
/>
</FormControl>
)}
control={control}
name="name"
/>
)}
control={control}
name="name"
/>
</ProjectPermissionCan>
</div>
<ProjectPermissionCan I={ProjectPermissionActions.Edit} a={ProjectPermissionSub.Workspace}>
{(isAllowed) => (