mirror of
https://github.com/fosrl/pangolin.git
synced 2026-03-12 13:46:39 +00:00
🚧 wip
This commit is contained in:
@@ -35,6 +35,8 @@ import { useEnvContext } from "@app/hooks/useEnvContext";
|
||||
import { useTranslations } from "next-intl";
|
||||
import { CheckboxWithLabel } from "./ui/checkbox";
|
||||
import { usePaidStatus } from "@app/hooks/usePaidStatus";
|
||||
import { build } from "@server/build";
|
||||
import { PaidFeaturesAlert } from "./PaidFeaturesAlert";
|
||||
|
||||
type CreateRoleFormProps = {
|
||||
open: boolean;
|
||||
@@ -165,7 +167,9 @@ export default function CreateRoleForm({
|
||||
</FormItem>
|
||||
)}
|
||||
/>
|
||||
{isPaidUser && (
|
||||
{build !== "oss" && (
|
||||
<>
|
||||
<PaidFeaturesAlert />
|
||||
<FormField
|
||||
control={form.control}
|
||||
name="requireDeviceApproval"
|
||||
@@ -174,6 +178,9 @@ export default function CreateRoleForm({
|
||||
<FormControl>
|
||||
<CheckboxWithLabel
|
||||
{...field}
|
||||
disabled={
|
||||
!isPaidUser
|
||||
}
|
||||
value={undefined}
|
||||
defaultChecked={
|
||||
field.value
|
||||
@@ -194,6 +201,7 @@ export default function CreateRoleForm({
|
||||
</FormItem>
|
||||
)}
|
||||
/>
|
||||
</>
|
||||
)}
|
||||
</form>
|
||||
</Form>
|
||||
|
||||
Reference in New Issue
Block a user