@xk2800/nextjs-template 0.7.2-beta.4 → 0.7.2-beta.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3,39 +3,57 @@
3
3
  import * as React from "react"
4
4
  import { Dialog as DialogPrimitive } from "radix-ui"
5
5
  import { XIcon } from "lucide-react"
6
+ import { Drawer } from "vaul"
6
7
 
8
+ import { useIsMobile } from "../../hooks/use-mobile"
7
9
  import { cn } from "../../lib/utils"
8
10
 
11
+ // Below 768px (useIsMobile) the dialog renders as a vaul drawer: bottom sheet with a
12
+ // grab handle and swipe-down-to-dismiss. vaul has its own Radix instance, so every
13
+ // part must come from the same primitive set; the root picks it and shares it via context.
14
+ const MobileContext = React.createContext(false)
15
+ const usePrimitive = () => (React.useContext(MobileContext) ? Drawer : DialogPrimitive)
16
+
9
17
  function Dialog({
10
18
  ...props
11
19
  }: React.ComponentProps<typeof DialogPrimitive.Root>) {
12
- return <DialogPrimitive.Root data-slot="dialog" {...props} />
20
+ const isMobile = useIsMobile()
21
+ const Root = isMobile ? Drawer.Root : DialogPrimitive.Root
22
+ return (
23
+ <MobileContext.Provider value={isMobile}>
24
+ <Root data-slot="dialog" {...props} />
25
+ </MobileContext.Provider>
26
+ )
13
27
  }
14
28
 
15
29
  function DialogTrigger({
16
30
  ...props
17
31
  }: React.ComponentProps<typeof DialogPrimitive.Trigger>) {
18
- return <DialogPrimitive.Trigger data-slot="dialog-trigger" {...props} />
32
+ const P = usePrimitive()
33
+ return <P.Trigger data-slot="dialog-trigger" {...props} />
19
34
  }
20
35
 
21
36
  function DialogPortal({
22
37
  ...props
23
38
  }: React.ComponentProps<typeof DialogPrimitive.Portal>) {
24
- return <DialogPrimitive.Portal data-slot="dialog-portal" {...props} />
39
+ const P = usePrimitive()
40
+ return <P.Portal data-slot="dialog-portal" {...props} />
25
41
  }
26
42
 
27
43
  function DialogClose({
28
44
  ...props
29
45
  }: React.ComponentProps<typeof DialogPrimitive.Close>) {
30
- return <DialogPrimitive.Close data-slot="dialog-close" {...props} />
46
+ const P = usePrimitive()
47
+ return <P.Close data-slot="dialog-close" {...props} />
31
48
  }
32
49
 
33
50
  function DialogOverlay({
34
51
  className,
35
52
  ...props
36
53
  }: React.ComponentProps<typeof DialogPrimitive.Overlay>) {
54
+ const P = usePrimitive()
37
55
  return (
38
- <DialogPrimitive.Overlay
56
+ <P.Overlay
39
57
  data-slot="dialog-overlay"
40
58
  className={cn(
41
59
  "data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",
@@ -54,28 +72,41 @@ function DialogContent({
54
72
  }: React.ComponentProps<typeof DialogPrimitive.Content> & {
55
73
  showCloseButton?: boolean
56
74
  }) {
75
+ const isMobile = React.useContext(MobileContext)
76
+ const P = usePrimitive()
57
77
  return (
58
78
  <DialogPortal data-slot="dialog-portal">
59
79
  <DialogOverlay />
60
- <DialogPrimitive.Content
80
+ <P.Content
61
81
  data-slot="dialog-content"
62
82
  className={cn(
63
- "bg-background data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border-(length:--surface-border-width) border-(--surface-border-color) p-6 shadow-(--dialog-shadow) duration-200 sm:max-w-lg",
83
+ "bg-background fixed z-50 grid gap-4 border-(length:--surface-border-width) border-(--surface-border-color) p-6 shadow-(--dialog-shadow)",
84
+ isMobile
85
+ ? "flex flex-col inset-x-0 bottom-0 max-h-[90dvh] rounded-t-xl pb-[max(1.5rem,env(safe-area-inset-bottom))]"
86
+ : "data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 top-[50%] left-[50%] max-h-[calc(100dvh-2rem)] w-full max-w-[calc(100%-2rem)] overflow-y-auto translate-x-[-50%] translate-y-[-50%] rounded-lg duration-200 sm:max-w-lg",
64
87
  className
65
88
  )}
66
89
  {...props}
67
90
  >
68
- {children}
91
+ {isMobile && (
92
+ <div aria-hidden className="bg-muted-foreground/30 mx-auto -mt-2 h-1.5 w-12 shrink-0 rounded-full" />
93
+ )}
94
+ {isMobile ? (
95
+ // Only this wrapper scrolls, and only when the content is taller than the drawer.
96
+ <div className="grid min-h-0 gap-4 overflow-y-auto overscroll-contain">{children}</div>
97
+ ) : (
98
+ children
99
+ )}
69
100
  {showCloseButton && (
70
- <DialogPrimitive.Close
101
+ <P.Close
71
102
  data-slot="dialog-close"
72
103
  className="ring-offset-background focus:ring-ring data-[state=open]:bg-accent data-[state=open]:text-muted-foreground absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4"
73
104
  >
74
105
  <XIcon />
75
106
  <span className="sr-only">Close</span>
76
- </DialogPrimitive.Close>
107
+ </P.Close>
77
108
  )}
78
- </DialogPrimitive.Content>
109
+ </P.Content>
79
110
  </DialogPortal>
80
111
  )
81
112
  }
@@ -107,8 +138,9 @@ function DialogTitle({
107
138
  className,
108
139
  ...props
109
140
  }: React.ComponentProps<typeof DialogPrimitive.Title>) {
141
+ const P = usePrimitive()
110
142
  return (
111
- <DialogPrimitive.Title
143
+ <P.Title
112
144
  data-slot="dialog-title"
113
145
  className={cn("text-lg leading-none font-semibold", className)}
114
146
  {...props}
@@ -120,8 +152,9 @@ function DialogDescription({
120
152
  className,
121
153
  ...props
122
154
  }: React.ComponentProps<typeof DialogPrimitive.Description>) {
155
+ const P = usePrimitive()
123
156
  return (
124
- <DialogPrimitive.Description
157
+ <P.Description
125
158
  data-slot="dialog-description"
126
159
  className={cn("text-muted-foreground text-sm", className)}
127
160
  {...props}
@@ -27,8 +27,8 @@ declare const getCurrentSession: () => Promise<{
27
27
  image?: string | null | undefined | undefined;
28
28
  role: string | null | undefined;
29
29
  banned: boolean | null | undefined;
30
- banExpires?: Date | null | undefined;
31
30
  banReason?: string | null | undefined;
31
+ banExpires?: Date | null | undefined;
32
32
  twoFactorEnabled: boolean | null | undefined;
33
33
  };
34
34
  } | null>;
@@ -50,8 +50,8 @@ declare const requireAuth: () => Promise<{
50
50
  name: string;
51
51
  image?: string | null | undefined | undefined;
52
52
  banned: boolean | null | undefined;
53
- banExpires?: Date | null | undefined;
54
53
  banReason?: string | null | undefined;
54
+ banExpires?: Date | null | undefined;
55
55
  twoFactorEnabled: boolean | null | undefined;
56
56
  };
57
57
  session: {
@@ -84,8 +84,8 @@ declare function requireRole(requiredRole: 'user' | 'admin'): Promise<{
84
84
  name: string;
85
85
  image?: string | null | undefined | undefined;
86
86
  banned: boolean | null | undefined;
87
- banExpires?: Date | null | undefined;
88
87
  banReason?: string | null | undefined;
88
+ banExpires?: Date | null | undefined;
89
89
  twoFactorEnabled: boolean | null | undefined;
90
90
  };
91
91
  session: {
@@ -27,8 +27,8 @@ declare const getCurrentSession: () => Promise<{
27
27
  image?: string | null | undefined | undefined;
28
28
  role: string | null | undefined;
29
29
  banned: boolean | null | undefined;
30
- banExpires?: Date | null | undefined;
31
30
  banReason?: string | null | undefined;
31
+ banExpires?: Date | null | undefined;
32
32
  twoFactorEnabled: boolean | null | undefined;
33
33
  };
34
34
  } | null>;
@@ -50,8 +50,8 @@ declare const requireAuth: () => Promise<{
50
50
  name: string;
51
51
  image?: string | null | undefined | undefined;
52
52
  banned: boolean | null | undefined;
53
- banExpires?: Date | null | undefined;
54
53
  banReason?: string | null | undefined;
54
+ banExpires?: Date | null | undefined;
55
55
  twoFactorEnabled: boolean | null | undefined;
56
56
  };
57
57
  session: {
@@ -84,8 +84,8 @@ declare function requireRole(requiredRole: 'user' | 'admin'): Promise<{
84
84
  name: string;
85
85
  image?: string | null | undefined | undefined;
86
86
  banned: boolean | null | undefined;
87
- banExpires?: Date | null | undefined;
88
87
  banReason?: string | null | undefined;
88
+ banExpires?: Date | null | undefined;
89
89
  twoFactorEnabled: boolean | null | undefined;
90
90
  };
91
91
  session: {
@@ -826,8 +826,8 @@ declare const authClient: better_auth_react.ReactAuthClient<{
826
826
  $Infer: {
827
827
  body: {
828
828
  permissions: {
829
- readonly user?: ("set-role" | "delete" | "update" | "list" | "create" | "ban" | "impersonate" | "impersonate-admins" | "set-password" | "set-email" | "get")[] | undefined;
830
- readonly session?: ("delete" | "list" | "revoke")[] | undefined;
829
+ readonly user?: ("create" | "list" | "set-role" | "ban" | "impersonate" | "impersonate-admins" | "delete" | "set-password" | "set-email" | "get" | "update")[] | undefined;
830
+ readonly session?: ("list" | "delete" | "revoke")[] | undefined;
831
831
  };
832
832
  } & {
833
833
  userId?: string | undefined;
@@ -916,8 +916,8 @@ declare const authClient: better_auth_react.ReactAuthClient<{
916
916
  admin: {
917
917
  checkRolePermission: <R extends "user" | "admin">(data: {
918
918
  permissions: {
919
- readonly user?: ("set-role" | "delete" | "update" | "list" | "create" | "ban" | "impersonate" | "impersonate-admins" | "set-password" | "set-email" | "get")[] | undefined;
920
- readonly session?: ("delete" | "list" | "revoke")[] | undefined;
919
+ readonly user?: ("create" | "list" | "set-role" | "ban" | "impersonate" | "impersonate-admins" | "delete" | "set-password" | "set-email" | "get" | "update")[] | undefined;
920
+ readonly session?: ("list" | "delete" | "revoke")[] | undefined;
921
921
  };
922
922
  } & {
923
923
  role: R;
@@ -2423,8 +2423,8 @@ declare const useSession: () => {
2423
2423
  banned: boolean | null | undefined;
2424
2424
  } & {
2425
2425
  role?: string | null | undefined;
2426
- banExpires?: Date | null | undefined;
2427
2426
  banReason?: string | null | undefined;
2427
+ banExpires?: Date | null | undefined;
2428
2428
  } & {
2429
2429
  twoFactorEnabled: boolean | null | undefined;
2430
2430
  } & {}>;
@@ -2450,7 +2450,7 @@ declare const useSession: () => {
2450
2450
  };
2451
2451
  declare const signIn: {
2452
2452
  social: <FetchOptions extends better_auth.ClientFetchOption<Partial<{
2453
- provider: "github" | "apple" | "atlassian" | "cloudflare" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "railway" | "vercel" | "wechat" | (string & {});
2453
+ provider: (string & {}) | "github" | "apple" | "atlassian" | "cloudflare" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "railway" | "vercel" | "wechat";
2454
2454
  callbackURL?: string | undefined;
2455
2455
  newUserCallbackURL?: string | undefined;
2456
2456
  errorCallbackURL?: string | undefined;
@@ -2475,7 +2475,7 @@ declare const signIn: {
2475
2475
  additionalParams?: Record<string, string> | undefined;
2476
2476
  additionalData?: Record<string, any> | undefined;
2477
2477
  }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, string | undefined> | undefined>>(data_0: better_auth.Prettify<Omit<{
2478
- provider: "github" | "apple" | "atlassian" | "cloudflare" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "railway" | "vercel" | "wechat" | (string & {});
2478
+ provider: (string & {}) | "github" | "apple" | "atlassian" | "cloudflare" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "railway" | "vercel" | "wechat";
2479
2479
  callbackURL?: string | undefined;
2480
2480
  newUserCallbackURL?: string | undefined;
2481
2481
  errorCallbackURL?: string | undefined;
@@ -2502,7 +2502,7 @@ declare const signIn: {
2502
2502
  } & {
2503
2503
  fetchOptions?: FetchOptions | undefined;
2504
2504
  }, "provider"> & {
2505
- provider: "github" | "apple" | "atlassian" | "cloudflare" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "railway" | "vercel" | "wechat" | (string & {});
2505
+ provider: (string & {}) | "github" | "apple" | "atlassian" | "cloudflare" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "railway" | "vercel" | "wechat";
2506
2506
  fetchOptions?: FetchOptions | undefined;
2507
2507
  }>, data_1?: FetchOptions | undefined) => Promise<_better_fetch_fetch.BetterFetchResponse<{
2508
2508
  redirect: boolean;
@@ -2533,8 +2533,8 @@ declare const signIn: {
2533
2533
  banned: boolean | null | undefined;
2534
2534
  } & {
2535
2535
  role?: string | null | undefined;
2536
- banExpires?: Date | null | undefined;
2537
2536
  banReason?: string | null | undefined;
2537
+ banExpires?: Date | null | undefined;
2538
2538
  } & {
2539
2539
  twoFactorEnabled: boolean | null | undefined;
2540
2540
  } & {}>;
@@ -2581,8 +2581,8 @@ declare const signIn: {
2581
2581
  banned: boolean | null | undefined;
2582
2582
  } & {
2583
2583
  role?: string | null | undefined;
2584
- banExpires?: Date | null | undefined;
2585
2584
  banReason?: string | null | undefined;
2585
+ banExpires?: Date | null | undefined;
2586
2586
  } & {
2587
2587
  twoFactorEnabled: boolean | null | undefined;
2588
2588
  } & {}>;
@@ -3481,8 +3481,8 @@ declare const signUp: {
3481
3481
  $Infer: {
3482
3482
  body: {
3483
3483
  permissions: {
3484
- readonly user?: ("set-role" | "delete" | "update" | "list" | "create" | "ban" | "impersonate" | "impersonate-admins" | "set-password" | "set-email" | "get")[] | undefined;
3485
- readonly session?: ("delete" | "list" | "revoke")[] | undefined;
3484
+ readonly user?: ("create" | "list" | "set-role" | "ban" | "impersonate" | "impersonate-admins" | "delete" | "set-password" | "set-email" | "get" | "update")[] | undefined;
3485
+ readonly session?: ("list" | "delete" | "revoke")[] | undefined;
3486
3486
  };
3487
3487
  } & {
3488
3488
  userId?: string | undefined;
@@ -3571,8 +3571,8 @@ declare const signUp: {
3571
3571
  admin: {
3572
3572
  checkRolePermission: <R extends "user" | "admin">(data: {
3573
3573
  permissions: {
3574
- readonly user?: ("set-role" | "delete" | "update" | "list" | "create" | "ban" | "impersonate" | "impersonate-admins" | "set-password" | "set-email" | "get")[] | undefined;
3575
- readonly session?: ("delete" | "list" | "revoke")[] | undefined;
3574
+ readonly user?: ("create" | "list" | "set-role" | "ban" | "impersonate" | "impersonate-admins" | "delete" | "set-password" | "set-email" | "get" | "update")[] | undefined;
3575
+ readonly session?: ("list" | "delete" | "revoke")[] | undefined;
3576
3576
  };
3577
3577
  } & {
3578
3578
  role: R;
@@ -5155,8 +5155,8 @@ declare const signUp: {
5155
5155
  banned: boolean | null | undefined;
5156
5156
  } & {
5157
5157
  role?: string | null | undefined;
5158
- banExpires?: Date | null | undefined;
5159
5158
  banReason?: string | null | undefined;
5159
+ banExpires?: Date | null | undefined;
5160
5160
  } & {
5161
5161
  twoFactorEnabled: boolean | null | undefined;
5162
5162
  } & {}>;
@@ -5184,8 +5184,8 @@ declare const signUp: {
5184
5184
  banned: boolean | null | undefined;
5185
5185
  } & {
5186
5186
  role?: string | null | undefined;
5187
- banExpires?: Date | null | undefined;
5188
5187
  banReason?: string | null | undefined;
5188
+ banExpires?: Date | null | undefined;
5189
5189
  } & {
5190
5190
  twoFactorEnabled: boolean | null | undefined;
5191
5191
  } & {}>;
@@ -826,8 +826,8 @@ declare const authClient: better_auth_react.ReactAuthClient<{
826
826
  $Infer: {
827
827
  body: {
828
828
  permissions: {
829
- readonly user?: ("set-role" | "delete" | "update" | "list" | "create" | "ban" | "impersonate" | "impersonate-admins" | "set-password" | "set-email" | "get")[] | undefined;
830
- readonly session?: ("delete" | "list" | "revoke")[] | undefined;
829
+ readonly user?: ("create" | "list" | "set-role" | "ban" | "impersonate" | "impersonate-admins" | "delete" | "set-password" | "set-email" | "get" | "update")[] | undefined;
830
+ readonly session?: ("list" | "delete" | "revoke")[] | undefined;
831
831
  };
832
832
  } & {
833
833
  userId?: string | undefined;
@@ -916,8 +916,8 @@ declare const authClient: better_auth_react.ReactAuthClient<{
916
916
  admin: {
917
917
  checkRolePermission: <R extends "user" | "admin">(data: {
918
918
  permissions: {
919
- readonly user?: ("set-role" | "delete" | "update" | "list" | "create" | "ban" | "impersonate" | "impersonate-admins" | "set-password" | "set-email" | "get")[] | undefined;
920
- readonly session?: ("delete" | "list" | "revoke")[] | undefined;
919
+ readonly user?: ("create" | "list" | "set-role" | "ban" | "impersonate" | "impersonate-admins" | "delete" | "set-password" | "set-email" | "get" | "update")[] | undefined;
920
+ readonly session?: ("list" | "delete" | "revoke")[] | undefined;
921
921
  };
922
922
  } & {
923
923
  role: R;
@@ -2423,8 +2423,8 @@ declare const useSession: () => {
2423
2423
  banned: boolean | null | undefined;
2424
2424
  } & {
2425
2425
  role?: string | null | undefined;
2426
- banExpires?: Date | null | undefined;
2427
2426
  banReason?: string | null | undefined;
2427
+ banExpires?: Date | null | undefined;
2428
2428
  } & {
2429
2429
  twoFactorEnabled: boolean | null | undefined;
2430
2430
  } & {}>;
@@ -2450,7 +2450,7 @@ declare const useSession: () => {
2450
2450
  };
2451
2451
  declare const signIn: {
2452
2452
  social: <FetchOptions extends better_auth.ClientFetchOption<Partial<{
2453
- provider: "github" | "apple" | "atlassian" | "cloudflare" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "railway" | "vercel" | "wechat" | (string & {});
2453
+ provider: (string & {}) | "github" | "apple" | "atlassian" | "cloudflare" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "railway" | "vercel" | "wechat";
2454
2454
  callbackURL?: string | undefined;
2455
2455
  newUserCallbackURL?: string | undefined;
2456
2456
  errorCallbackURL?: string | undefined;
@@ -2475,7 +2475,7 @@ declare const signIn: {
2475
2475
  additionalParams?: Record<string, string> | undefined;
2476
2476
  additionalData?: Record<string, any> | undefined;
2477
2477
  }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, string | undefined> | undefined>>(data_0: better_auth.Prettify<Omit<{
2478
- provider: "github" | "apple" | "atlassian" | "cloudflare" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "railway" | "vercel" | "wechat" | (string & {});
2478
+ provider: (string & {}) | "github" | "apple" | "atlassian" | "cloudflare" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "railway" | "vercel" | "wechat";
2479
2479
  callbackURL?: string | undefined;
2480
2480
  newUserCallbackURL?: string | undefined;
2481
2481
  errorCallbackURL?: string | undefined;
@@ -2502,7 +2502,7 @@ declare const signIn: {
2502
2502
  } & {
2503
2503
  fetchOptions?: FetchOptions | undefined;
2504
2504
  }, "provider"> & {
2505
- provider: "github" | "apple" | "atlassian" | "cloudflare" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "railway" | "vercel" | "wechat" | (string & {});
2505
+ provider: (string & {}) | "github" | "apple" | "atlassian" | "cloudflare" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "railway" | "vercel" | "wechat";
2506
2506
  fetchOptions?: FetchOptions | undefined;
2507
2507
  }>, data_1?: FetchOptions | undefined) => Promise<_better_fetch_fetch.BetterFetchResponse<{
2508
2508
  redirect: boolean;
@@ -2533,8 +2533,8 @@ declare const signIn: {
2533
2533
  banned: boolean | null | undefined;
2534
2534
  } & {
2535
2535
  role?: string | null | undefined;
2536
- banExpires?: Date | null | undefined;
2537
2536
  banReason?: string | null | undefined;
2537
+ banExpires?: Date | null | undefined;
2538
2538
  } & {
2539
2539
  twoFactorEnabled: boolean | null | undefined;
2540
2540
  } & {}>;
@@ -2581,8 +2581,8 @@ declare const signIn: {
2581
2581
  banned: boolean | null | undefined;
2582
2582
  } & {
2583
2583
  role?: string | null | undefined;
2584
- banExpires?: Date | null | undefined;
2585
2584
  banReason?: string | null | undefined;
2585
+ banExpires?: Date | null | undefined;
2586
2586
  } & {
2587
2587
  twoFactorEnabled: boolean | null | undefined;
2588
2588
  } & {}>;
@@ -3481,8 +3481,8 @@ declare const signUp: {
3481
3481
  $Infer: {
3482
3482
  body: {
3483
3483
  permissions: {
3484
- readonly user?: ("set-role" | "delete" | "update" | "list" | "create" | "ban" | "impersonate" | "impersonate-admins" | "set-password" | "set-email" | "get")[] | undefined;
3485
- readonly session?: ("delete" | "list" | "revoke")[] | undefined;
3484
+ readonly user?: ("create" | "list" | "set-role" | "ban" | "impersonate" | "impersonate-admins" | "delete" | "set-password" | "set-email" | "get" | "update")[] | undefined;
3485
+ readonly session?: ("list" | "delete" | "revoke")[] | undefined;
3486
3486
  };
3487
3487
  } & {
3488
3488
  userId?: string | undefined;
@@ -3571,8 +3571,8 @@ declare const signUp: {
3571
3571
  admin: {
3572
3572
  checkRolePermission: <R extends "user" | "admin">(data: {
3573
3573
  permissions: {
3574
- readonly user?: ("set-role" | "delete" | "update" | "list" | "create" | "ban" | "impersonate" | "impersonate-admins" | "set-password" | "set-email" | "get")[] | undefined;
3575
- readonly session?: ("delete" | "list" | "revoke")[] | undefined;
3574
+ readonly user?: ("create" | "list" | "set-role" | "ban" | "impersonate" | "impersonate-admins" | "delete" | "set-password" | "set-email" | "get" | "update")[] | undefined;
3575
+ readonly session?: ("list" | "delete" | "revoke")[] | undefined;
3576
3576
  };
3577
3577
  } & {
3578
3578
  role: R;
@@ -5155,8 +5155,8 @@ declare const signUp: {
5155
5155
  banned: boolean | null | undefined;
5156
5156
  } & {
5157
5157
  role?: string | null | undefined;
5158
- banExpires?: Date | null | undefined;
5159
5158
  banReason?: string | null | undefined;
5159
+ banExpires?: Date | null | undefined;
5160
5160
  } & {
5161
5161
  twoFactorEnabled: boolean | null | undefined;
5162
5162
  } & {}>;
@@ -5184,8 +5184,8 @@ declare const signUp: {
5184
5184
  banned: boolean | null | undefined;
5185
5185
  } & {
5186
5186
  role?: string | null | undefined;
5187
- banExpires?: Date | null | undefined;
5188
5187
  banReason?: string | null | undefined;
5188
+ banExpires?: Date | null | undefined;
5189
5189
  } & {
5190
5190
  twoFactorEnabled: boolean | null | undefined;
5191
5191
  } & {}>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xk2800/nextjs-template",
3
- "version": "0.7.2-beta.4",
3
+ "version": "0.7.2-beta.5",
4
4
  "private": false,
5
5
  "repository": {
6
6
  "type": "git",
@@ -361,6 +361,7 @@
361
361
  "resend": "^6.4.2",
362
362
  "server-only": "^0.0.1",
363
363
  "ua-parser-js": "2.0.10",
364
+ "vaul": "^1.1.2",
364
365
  "web-push": "^3.6.7",
365
366
  "zod": "^4.6.5"
366
367
  },