lock hashed link until further notice
This commit is contained in:
parent
bcac078cee
commit
afd0d2e0cd
|
@ -108,7 +108,8 @@ export const EventAdvancedTab = ({ eventType, team }: Pick<EventTypeSetupProps,
|
|||
);
|
||||
};
|
||||
|
||||
const { shouldLockDisableProps } = useLockedFieldsManager(eventType, formMethods, t);
|
||||
const { isChildrenManagedEventType, isManagedEventType, shouldLockDisableProps, shouldLockIndicator } =
|
||||
useLockedFieldsManager(eventType, formMethods, t);
|
||||
const eventNamePlaceholder = getEventName({
|
||||
...eventNameObject,
|
||||
eventName: formMethods.watch("eventName"),
|
||||
|
@ -306,7 +307,9 @@ export const EventAdvancedTab = ({ eventType, team }: Pick<EventTypeSetupProps,
|
|||
<Info className="ml-1.5 h-4 w-4 cursor-pointer" />
|
||||
</a>
|
||||
}
|
||||
{...shouldLockDisableProps("hashedLinkCheck")}
|
||||
{...(isChildrenManagedEventType
|
||||
? { disabled: true, LockedIcon: shouldLockIndicator("hashedLink", false) }
|
||||
: {})}
|
||||
description={t("private_link_description", { appName: APP_NAME })}
|
||||
checked={hashedLinkVisible}
|
||||
onCheckedChange={(e) => {
|
||||
|
|
|
@ -139,7 +139,7 @@ const useLockedFieldsManager = (
|
|||
// eslint-disable-next-line react-hooks/rules-of-hooks
|
||||
fieldStates[fieldName] = useState(getLockedInitState(fieldName));
|
||||
}
|
||||
console.log("fieldStates", fieldStates);
|
||||
|
||||
return LockedIndicator(
|
||||
isManagedEventType,
|
||||
fieldStates[fieldName],
|
||||
|
|
Loading…
Reference in New Issue
Block a user