aboutsummaryrefslogtreecommitdiff
path: root/jb-ui/src/components/ui
diff options
context:
space:
mode:
authorMax Nanis2026-09-10 17:46:41 -0700
committerMax Nanis2026-09-10 17:46:41 -0700
commited201936813d9a720b51e6cb40a05267b94e7314 (patch)
treef675f6a0d91ed1d17f654e40936e8c1ca9ccf141 /jb-ui/src/components/ui
parent0ac38066402762dc5fa24f2ffa2170681a6eddb1 (diff)
downloadamt-jb-ed201936813d9a720b51e6cb40a05267b94e7314.tar.gz
amt-jb-ed201936813d9a720b51e6cb40a05267b94e7314.zip
Typescript prettier
Committing seperate so it's easier to see actual changes.
Diffstat (limited to 'jb-ui/src/components/ui')
-rw-r--r--jb-ui/src/components/ui/button.tsx20
-rw-r--r--jb-ui/src/components/ui/checkbox.tsx14
-rw-r--r--jb-ui/src/components/ui/confetti.tsx98
-rw-r--r--jb-ui/src/components/ui/dot-pattern.tsx60
-rw-r--r--jb-ui/src/components/ui/field.tsx72
-rw-r--r--jb-ui/src/components/ui/label.tsx12
-rw-r--r--jb-ui/src/components/ui/magic-card.tsx70
-rw-r--r--jb-ui/src/components/ui/pagination.tsx30
-rw-r--r--jb-ui/src/components/ui/separator.tsx14
-rw-r--r--jb-ui/src/components/ui/skeleton.tsx6
10 files changed, 198 insertions, 198 deletions
diff --git a/jb-ui/src/components/ui/button.tsx b/jb-ui/src/components/ui/button.tsx
index b5ea4ab..d2176b4 100644
--- a/jb-ui/src/components/ui/button.tsx
+++ b/jb-ui/src/components/ui/button.tsx
@@ -1,8 +1,8 @@
-import * as React from "react"
-import { cva, type VariantProps } from "class-variance-authority"
-import { Slot } from "radix-ui"
+import * as React from "react";
+import { cva, type VariantProps } from "class-variance-authority";
+import { Slot } from "radix-ui";
-import { cn } from "@/lib/utils"
+import { cn } from "@/lib/utils";
const buttonVariants = cva(
"inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",
@@ -35,8 +35,8 @@ const buttonVariants = cva(
variant: "default",
size: "default",
},
- }
-)
+ },
+);
function Button({
className,
@@ -46,9 +46,9 @@ function Button({
...props
}: React.ComponentProps<"button"> &
VariantProps<typeof buttonVariants> & {
- asChild?: boolean
+ asChild?: boolean;
}) {
- const Comp = asChild ? Slot.Root : "button"
+ const Comp = asChild ? Slot.Root : "button";
return (
<Comp
@@ -58,7 +58,7 @@ function Button({
className={cn(buttonVariants({ variant, size, className }))}
{...props}
/>
- )
+ );
}
-export { Button, buttonVariants }
+export { Button, buttonVariants };
diff --git a/jb-ui/src/components/ui/checkbox.tsx b/jb-ui/src/components/ui/checkbox.tsx
index 0e2a6cd..f24ad45 100644
--- a/jb-ui/src/components/ui/checkbox.tsx
+++ b/jb-ui/src/components/ui/checkbox.tsx
@@ -1,8 +1,8 @@
-import * as React from "react"
-import * as CheckboxPrimitive from "@radix-ui/react-checkbox"
-import { CheckIcon } from "lucide-react"
+import * as React from "react";
+import * as CheckboxPrimitive from "@radix-ui/react-checkbox";
+import { CheckIcon } from "lucide-react";
-import { cn } from "@/lib/utils"
+import { cn } from "@/lib/utils";
function Checkbox({
className,
@@ -13,7 +13,7 @@ function Checkbox({
data-slot="checkbox"
className={cn(
"peer border-input dark:bg-input/30 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground dark:data-[state=checked]:bg-primary data-[state=checked]:border-primary focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive size-4 shrink-0 rounded-[4px] border shadow-xs transition-shadow outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50",
- className
+ className,
)}
{...props}
>
@@ -24,7 +24,7 @@ function Checkbox({
<CheckIcon className="size-3.5" />
</CheckboxPrimitive.Indicator>
</CheckboxPrimitive.Root>
- )
+ );
}
-export { Checkbox }
+export { Checkbox };
diff --git a/jb-ui/src/components/ui/confetti.tsx b/jb-ui/src/components/ui/confetti.tsx
index e0d353a..57d3273 100644
--- a/jb-ui/src/components/ui/confetti.tsx
+++ b/jb-ui/src/components/ui/confetti.tsx
@@ -1,4 +1,4 @@
-import type { ReactNode } from "react"
+import type { ReactNode } from "react";
import React, {
createContext,
forwardRef,
@@ -7,30 +7,30 @@ import React, {
useImperativeHandle,
useMemo,
useRef,
-} from "react"
+} from "react";
import type {
GlobalOptions as ConfettiGlobalOptions,
CreateTypes as ConfettiInstance,
Options as ConfettiOptions,
-} from "canvas-confetti"
-import confetti from "canvas-confetti"
+} from "canvas-confetti";
+import confetti from "canvas-confetti";
-import { Button } from "@/components/ui/button"
+import { Button } from "@/components/ui/button";
type Api = {
- fire: (options?: ConfettiOptions) => void
-}
+ fire: (options?: ConfettiOptions) => void;
+};
type Props = React.ComponentPropsWithRef<"canvas"> & {
- options?: ConfettiOptions
- globalOptions?: ConfettiGlobalOptions
- manualstart?: boolean
- children?: ReactNode
-}
+ options?: ConfettiOptions;
+ globalOptions?: ConfettiGlobalOptions;
+ manualstart?: boolean;
+ children?: ReactNode;
+};
-export type ConfettiRef = Api | null
+export type ConfettiRef = Api | null;
-const ConfettiContext = createContext<Api>({} as Api)
+const ConfettiContext = createContext<Api>({} as Api);
// Define component first
const ConfettiComponent = forwardRef<ConfettiRef, Props>((props, ref) => {
@@ -40,76 +40,76 @@ const ConfettiComponent = forwardRef<ConfettiRef, Props>((props, ref) => {
manualstart = false,
children,
...rest
- } = props
- const instanceRef = useRef<ConfettiInstance | null>(null)
+ } = props;
+ const instanceRef = useRef<ConfettiInstance | null>(null);
const canvasRef = useCallback(
(node: HTMLCanvasElement) => {
if (node !== null) {
- if (instanceRef.current) return
+ if (instanceRef.current) return;
instanceRef.current = confetti.create(node, {
...globalOptions,
resize: true,
- })
+ });
} else {
if (instanceRef.current) {
- instanceRef.current.reset()
- instanceRef.current = null
+ instanceRef.current.reset();
+ instanceRef.current = null;
}
}
},
- [globalOptions]
- )
+ [globalOptions],
+ );
const fire = useCallback(
async (opts = {}) => {
try {
- await instanceRef.current?.({ ...options, ...opts })
+ await instanceRef.current?.({ ...options, ...opts });
} catch (error) {
- console.error("Confetti error:", error)
+ console.error("Confetti error:", error);
}
},
- [options]
- )
+ [options],
+ );
const api = useMemo(
() => ({
fire,
}),
- [fire]
- )
+ [fire],
+ );
- useImperativeHandle(ref, () => api, [api])
+ useImperativeHandle(ref, () => api, [api]);
useEffect(() => {
if (!manualstart) {
- ;(async () => {
+ (async () => {
try {
- await fire()
+ await fire();
} catch (error) {
- console.error("Confetti effect error:", error)
+ console.error("Confetti effect error:", error);
}
- })()
+ })();
}
- }, [manualstart, fire])
+ }, [manualstart, fire]);
return (
<ConfettiContext.Provider value={api}>
<canvas ref={canvasRef} {...rest} />
{children}
</ConfettiContext.Provider>
- )
-})
+ );
+});
// Set display name immediately
-ConfettiComponent.displayName = "Confetti"
+ConfettiComponent.displayName = "Confetti";
// Export as Confetti
-export const Confetti = ConfettiComponent
+export const Confetti = ConfettiComponent;
interface ConfettiButtonProps extends React.ComponentProps<"button"> {
options?: ConfettiOptions &
- ConfettiGlobalOptions & { canvas?: HTMLCanvasElement }
+ ConfettiGlobalOptions & { canvas?: HTMLCanvasElement };
}
const ConfettiButtonComponent = ({
@@ -119,28 +119,28 @@ const ConfettiButtonComponent = ({
}: ConfettiButtonProps) => {
const handleClick = async (event: React.MouseEvent<HTMLButtonElement>) => {
try {
- const rect = event.currentTarget.getBoundingClientRect()
- const x = rect.left + rect.width / 2
- const y = rect.top + rect.height / 2
+ const rect = event.currentTarget.getBoundingClientRect();
+ const x = rect.left + rect.width / 2;
+ const y = rect.top + rect.height / 2;
await confetti({
...options,
origin: {
x: x / window.innerWidth,
y: y / window.innerHeight,
},
- })
+ });
} catch (error) {
- console.error("Confetti button error:", error)
+ console.error("Confetti button error:", error);
}
- }
+ };
return (
<Button onClick={handleClick} {...props}>
{children}
</Button>
- )
-}
+ );
+};
-ConfettiButtonComponent.displayName = "ConfettiButton"
+ConfettiButtonComponent.displayName = "ConfettiButton";
-export const ConfettiButton = ConfettiButtonComponent
+export const ConfettiButton = ConfettiButtonComponent;
diff --git a/jb-ui/src/components/ui/dot-pattern.tsx b/jb-ui/src/components/ui/dot-pattern.tsx
index 9522b7f..a217a9b 100644
--- a/jb-ui/src/components/ui/dot-pattern.tsx
+++ b/jb-ui/src/components/ui/dot-pattern.tsx
@@ -1,7 +1,7 @@
-import React, { useEffect, useId, useRef, useState } from "react"
-import { motion } from "motion/react"
+import React, { useEffect, useId, useRef, useState } from "react";
+import { motion } from "motion/react";
-import { cn } from "@/lib/utils"
+import { cn } from "@/lib/utils";
/**
* DotPattern Component Props
@@ -17,16 +17,16 @@ import { cn } from "@/lib/utils"
* @param {boolean} [glow=false] - Whether dots should have a glowing animation effect
*/
interface DotPatternProps extends React.SVGProps<SVGSVGElement> {
- width?: number
- height?: number
- x?: number
- y?: number
- cx?: number
- cy?: number
- cr?: number
- className?: string
- glow?: boolean
- [key: string]: unknown
+ width?: number;
+ height?: number;
+ x?: number;
+ y?: number;
+ cx?: number;
+ cy?: number;
+ cr?: number;
+ className?: string;
+ glow?: boolean;
+ [key: string]: unknown;
}
/**
@@ -71,22 +71,22 @@ export function DotPattern({
glow = false,
...props
}: DotPatternProps) {
- const id = useId()
- const containerRef = useRef<SVGSVGElement>(null)
- const [dimensions, setDimensions] = useState({ width: 0, height: 0 })
+ const id = useId();
+ const containerRef = useRef<SVGSVGElement>(null);
+ const [dimensions, setDimensions] = useState({ width: 0, height: 0 });
useEffect(() => {
const updateDimensions = () => {
if (containerRef.current) {
- const { width, height } = containerRef.current.getBoundingClientRect()
- setDimensions({ width, height })
+ const { width, height } = containerRef.current.getBoundingClientRect();
+ setDimensions({ width, height });
}
- }
+ };
- updateDimensions()
- window.addEventListener("resize", updateDimensions)
- return () => window.removeEventListener("resize", updateDimensions)
- }, [])
+ updateDimensions();
+ window.addEventListener("resize", updateDimensions);
+ return () => window.removeEventListener("resize", updateDimensions);
+ }, []);
const dots = Array.from(
{
@@ -95,16 +95,16 @@ export function DotPattern({
Math.ceil(dimensions.height / height),
},
(_, i) => {
- const col = i % Math.ceil(dimensions.width / width)
- const row = Math.floor(i / Math.ceil(dimensions.width / width))
+ const col = i % Math.ceil(dimensions.width / width);
+ const row = Math.floor(i / Math.ceil(dimensions.width / width));
return {
x: col * width + cx,
y: row * height + cy,
delay: Math.random() * 5,
duration: Math.random() * 3 + 2,
- }
- }
- )
+ };
+ },
+ );
return (
<svg
@@ -112,7 +112,7 @@ export function DotPattern({
aria-hidden="true"
className={cn(
"pointer-events-none absolute inset-0 h-full w-full text-neutral-400/80",
- className
+ className,
)}
{...props}
>
@@ -152,5 +152,5 @@ export function DotPattern({
/>
))}
</svg>
- )
+ );
}
diff --git a/jb-ui/src/components/ui/field.tsx b/jb-ui/src/components/ui/field.tsx
index db0dc12..77546e5 100644
--- a/jb-ui/src/components/ui/field.tsx
+++ b/jb-ui/src/components/ui/field.tsx
@@ -1,9 +1,9 @@
-import { useMemo } from "react"
-import { cva, type VariantProps } from "class-variance-authority"
+import { useMemo } from "react";
+import { cva, type VariantProps } from "class-variance-authority";
-import { cn } from "@/lib/utils"
-import { Label } from "@/components/ui/label"
-import { Separator } from "@/components/ui/separator"
+import { cn } from "@/lib/utils";
+import { Label } from "@/components/ui/label";
+import { Separator } from "@/components/ui/separator";
function FieldSet({ className, ...props }: React.ComponentProps<"fieldset">) {
return (
@@ -12,11 +12,11 @@ function FieldSet({ className, ...props }: React.ComponentProps<"fieldset">) {
className={cn(
"flex flex-col gap-6",
"has-[>[data-slot=checkbox-group]]:gap-3 has-[>[data-slot=radio-group]]:gap-3",
- className
+ className,
)}
{...props}
/>
- )
+ );
}
function FieldLegend({
@@ -32,11 +32,11 @@ function FieldLegend({
"mb-3 font-medium",
"data-[variant=legend]:text-base",
"data-[variant=label]:text-sm",
- className
+ className,
)}
{...props}
/>
- )
+ );
}
function FieldGroup({ className, ...props }: React.ComponentProps<"div">) {
@@ -45,11 +45,11 @@ function FieldGroup({ className, ...props }: React.ComponentProps<"div">) {
data-slot="field-group"
className={cn(
"group/field-group @container/field-group flex w-full flex-col gap-7 data-[slot=checkbox-group]:gap-3 [&>[data-slot=field-group]]:gap-4",
- className
+ className,
)}
{...props}
/>
- )
+ );
}
const fieldVariants = cva(
@@ -73,8 +73,8 @@ const fieldVariants = cva(
defaultVariants: {
orientation: "vertical",
},
- }
-)
+ },
+);
function Field({
className,
@@ -89,7 +89,7 @@ function Field({
className={cn(fieldVariants({ orientation }), className)}
{...props}
/>
- )
+ );
}
function FieldContent({ className, ...props }: React.ComponentProps<"div">) {
@@ -98,11 +98,11 @@ function FieldContent({ className, ...props }: React.ComponentProps<"div">) {
data-slot="field-content"
className={cn(
"group/field-content flex flex-1 flex-col gap-1.5 leading-snug",
- className
+ className,
)}
{...props}
/>
- )
+ );
}
function FieldLabel({
@@ -116,11 +116,11 @@ function FieldLabel({
"group/field-label peer/field-label flex w-fit gap-2 leading-snug group-data-[disabled=true]/field:opacity-50",
"has-[>[data-slot=field]]:w-full has-[>[data-slot=field]]:flex-col has-[>[data-slot=field]]:rounded-md has-[>[data-slot=field]]:border [&>*]:data-[slot=field]:p-4",
"has-data-[state=checked]:bg-primary/5 has-data-[state=checked]:border-primary dark:has-data-[state=checked]:bg-primary/10",
- className
+ className,
)}
{...props}
/>
- )
+ );
}
function FieldTitle({ className, ...props }: React.ComponentProps<"div">) {
@@ -129,11 +129,11 @@ function FieldTitle({ className, ...props }: React.ComponentProps<"div">) {
data-slot="field-label"
className={cn(
"flex w-fit items-center gap-2 text-sm leading-snug font-medium group-data-[disabled=true]/field:opacity-50",
- className
+ className,
)}
{...props}
/>
- )
+ );
}
function FieldDescription({ className, ...props }: React.ComponentProps<"p">) {
@@ -144,11 +144,11 @@ function FieldDescription({ className, ...props }: React.ComponentProps<"p">) {
"text-muted-foreground text-sm leading-normal font-normal group-has-[[data-orientation=horizontal]]/field:text-balance",
"last:mt-0 nth-last-2:-mt-1 [[data-variant=legend]+&]:-mt-1.5",
"[&>a:hover]:text-primary [&>a]:underline [&>a]:underline-offset-4",
- className
+ className,
)}
{...props}
/>
- )
+ );
}
function FieldSeparator({
@@ -156,7 +156,7 @@ function FieldSeparator({
className,
...props
}: React.ComponentProps<"div"> & {
- children?: React.ReactNode
+ children?: React.ReactNode;
}) {
return (
<div
@@ -164,7 +164,7 @@ function FieldSeparator({
data-content={!!children}
className={cn(
"relative -my-2 h-5 text-sm group-data-[variant=outline]/field-group:-mb-2",
- className
+ className,
)}
{...props}
>
@@ -178,7 +178,7 @@ function FieldSeparator({
</span>
)}
</div>
- )
+ );
}
function FieldError({
@@ -187,37 +187,37 @@ function FieldError({
errors,
...props
}: React.ComponentProps<"div"> & {
- errors?: Array<{ message?: string } | undefined>
+ errors?: Array<{ message?: string } | undefined>;
}) {
const content = useMemo(() => {
if (children) {
- return children
+ return children;
}
if (!errors?.length) {
- return null
+ return null;
}
const uniqueErrors = [
...new Map(errors.map((error) => [error?.message, error])).values(),
- ]
+ ];
if (uniqueErrors?.length == 1) {
- return uniqueErrors[0]?.message
+ return uniqueErrors[0]?.message;
}
return (
<ul className="ml-4 flex list-disc flex-col gap-1">
{uniqueErrors.map(
(error, index) =>
- error?.message && <li key={index}>{error.message}</li>
+ error?.message && <li key={index}>{error.message}</li>,
)}
</ul>
- )
- }, [children, errors])
+ );
+ }, [children, errors]);
if (!content) {
- return null
+ return null;
}
return (
@@ -229,7 +229,7 @@ function FieldError({
>
{content}
</div>
- )
+ );
}
export {
@@ -243,4 +243,4 @@ export {
FieldSet,
FieldContent,
FieldTitle,
-}
+};
diff --git a/jb-ui/src/components/ui/label.tsx b/jb-ui/src/components/ui/label.tsx
index ef7133a..4ef28a9 100644
--- a/jb-ui/src/components/ui/label.tsx
+++ b/jb-ui/src/components/ui/label.tsx
@@ -1,7 +1,7 @@
-import * as React from "react"
-import * as LabelPrimitive from "@radix-ui/react-label"
+import * as React from "react";
+import * as LabelPrimitive from "@radix-ui/react-label";
-import { cn } from "@/lib/utils"
+import { cn } from "@/lib/utils";
function Label({
className,
@@ -12,11 +12,11 @@ function Label({
data-slot="label"
className={cn(
"flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50",
- className
+ className,
)}
{...props}
/>
- )
+ );
}
-export { Label }
+export { Label };
diff --git a/jb-ui/src/components/ui/magic-card.tsx b/jb-ui/src/components/ui/magic-card.tsx
index e6503d8..2b92e38 100644
--- a/jb-ui/src/components/ui/magic-card.tsx
+++ b/jb-ui/src/components/ui/magic-card.tsx
@@ -1,16 +1,16 @@
-import React, { useCallback, useEffect } from "react"
-import { motion, useMotionTemplate, useMotionValue } from "motion/react"
+import React, { useCallback, useEffect } from "react";
+import { motion, useMotionTemplate, useMotionValue } from "motion/react";
-import { cn } from "@/lib/utils"
+import { cn } from "@/lib/utils";
interface MagicCardProps {
- children?: React.ReactNode
- className?: string
- gradientSize?: number
- gradientColor?: string
- gradientOpacity?: number
- gradientFrom?: string
- gradientTo?: string
+ children?: React.ReactNode;
+ className?: string;
+ gradientSize?: number;
+ gradientColor?: string;
+ gradientOpacity?: number;
+ gradientFrom?: string;
+ gradientTo?: string;
}
export function MagicCard({
@@ -22,49 +22,49 @@ export function MagicCard({
gradientFrom = "#9E7AFF",
gradientTo = "#FE8BBB",
}: MagicCardProps) {
- const mouseX = useMotionValue(-gradientSize)
- const mouseY = useMotionValue(-gradientSize)
+ const mouseX = useMotionValue(-gradientSize);
+ const mouseY = useMotionValue(-gradientSize);
const reset = useCallback(() => {
- mouseX.set(-gradientSize)
- mouseY.set(-gradientSize)
- }, [gradientSize, mouseX, mouseY])
+ mouseX.set(-gradientSize);
+ mouseY.set(-gradientSize);
+ }, [gradientSize, mouseX, mouseY]);
const handlePointerMove = useCallback(
(e: React.PointerEvent<HTMLDivElement>) => {
- const rect = e.currentTarget.getBoundingClientRect()
- mouseX.set(e.clientX - rect.left)
- mouseY.set(e.clientY - rect.top)
+ const rect = e.currentTarget.getBoundingClientRect();
+ mouseX.set(e.clientX - rect.left);
+ mouseY.set(e.clientY - rect.top);
},
- [mouseX, mouseY]
- )
+ [mouseX, mouseY],
+ );
useEffect(() => {
- reset()
- }, [reset])
+ reset();
+ }, [reset]);
useEffect(() => {
const handleGlobalPointerOut = (e: PointerEvent) => {
if (!e.relatedTarget) {
- reset()
+ reset();
}
- }
+ };
const handleVisibility = () => {
if (document.visibilityState !== "visible") {
- reset()
+ reset();
}
- }
+ };
- window.addEventListener("pointerout", handleGlobalPointerOut)
- window.addEventListener("blur", reset)
- document.addEventListener("visibilitychange", handleVisibility)
+ window.addEventListener("pointerout", handleGlobalPointerOut);
+ window.addEventListener("blur", reset);
+ document.addEventListener("visibilitychange", handleVisibility);
return () => {
- window.removeEventListener("pointerout", handleGlobalPointerOut)
- window.removeEventListener("blur", reset)
- document.removeEventListener("visibilitychange", handleVisibility)
- }
- }, [reset])
+ window.removeEventListener("pointerout", handleGlobalPointerOut);
+ window.removeEventListener("blur", reset);
+ document.removeEventListener("visibilitychange", handleVisibility);
+ };
+ }, [reset]);
return (
<div
@@ -97,5 +97,5 @@ export function MagicCard({
/>
<div className="relative">{children}</div>
</div>
- )
+ );
}
diff --git a/jb-ui/src/components/ui/pagination.tsx b/jb-ui/src/components/ui/pagination.tsx
index 1dcfb0c..990f907 100644
--- a/jb-ui/src/components/ui/pagination.tsx
+++ b/jb-ui/src/components/ui/pagination.tsx
@@ -1,12 +1,12 @@
-import * as React from "react"
+import * as React from "react";
import {
ChevronLeftIcon,
ChevronRightIcon,
MoreHorizontalIcon,
-} from "lucide-react"
+} from "lucide-react";
-import { cn } from "@/lib/utils"
-import { buttonVariants, type Button } from "@/components/ui/button"
+import { cn } from "@/lib/utils";
+import { buttonVariants, type Button } from "@/components/ui/button";
function Pagination({ className, ...props }: React.ComponentProps<"nav">) {
return (
@@ -17,7 +17,7 @@ function Pagination({ className, ...props }: React.ComponentProps<"nav">) {
className={cn("mx-auto flex w-full justify-center", className)}
{...props}
/>
- )
+ );
}
function PaginationContent({
@@ -30,17 +30,17 @@ function PaginationContent({
className={cn("flex flex-row items-center gap-1", className)}
{...props}
/>
- )
+ );
}
function PaginationItem({ ...props }: React.ComponentProps<"li">) {
- return <li data-slot="pagination-item" {...props} />
+ return <li data-slot="pagination-item" {...props} />;
}
type PaginationLinkProps = {
- isActive?: boolean
+ isActive?: boolean;
} & Pick<React.ComponentProps<typeof Button>, "size"> &
- React.ComponentProps<"a">
+ React.ComponentProps<"a">;
function PaginationLink({
className,
@@ -58,11 +58,11 @@ function PaginationLink({
variant: isActive ? "outline" : "ghost",
size,
}),
- className
+ className,
)}
{...props}
/>
- )
+ );
}
function PaginationPrevious({
@@ -79,7 +79,7 @@ function PaginationPrevious({
<ChevronLeftIcon />
<span className="hidden sm:block">Previous</span>
</PaginationLink>
- )
+ );
}
function PaginationNext({
@@ -96,7 +96,7 @@ function PaginationNext({
<span className="hidden sm:block">Next</span>
<ChevronRightIcon />
</PaginationLink>
- )
+ );
}
function PaginationEllipsis({
@@ -113,7 +113,7 @@ function PaginationEllipsis({
<MoreHorizontalIcon className="size-4" />
<span className="sr-only">More pages</span>
</span>
- )
+ );
}
export {
@@ -124,4 +124,4 @@ export {
PaginationPrevious,
PaginationNext,
PaginationEllipsis,
-}
+};
diff --git a/jb-ui/src/components/ui/separator.tsx b/jb-ui/src/components/ui/separator.tsx
index 275381c..72c18e3 100644
--- a/jb-ui/src/components/ui/separator.tsx
+++ b/jb-ui/src/components/ui/separator.tsx
@@ -1,9 +1,9 @@
-"use client"
+"use client";
-import * as React from "react"
-import * as SeparatorPrimitive from "@radix-ui/react-separator"
+import * as React from "react";
+import * as SeparatorPrimitive from "@radix-ui/react-separator";
-import { cn } from "@/lib/utils"
+import { cn } from "@/lib/utils";
function Separator({
className,
@@ -18,11 +18,11 @@ function Separator({
orientation={orientation}
className={cn(
"bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px",
- className
+ className,
)}
{...props}
/>
- )
+ );
}
-export { Separator }
+export { Separator };
diff --git a/jb-ui/src/components/ui/skeleton.tsx b/jb-ui/src/components/ui/skeleton.tsx
index 32ea0ef..0168998 100644
--- a/jb-ui/src/components/ui/skeleton.tsx
+++ b/jb-ui/src/components/ui/skeleton.tsx
@@ -1,4 +1,4 @@
-import { cn } from "@/lib/utils"
+import { cn } from "@/lib/utils";
function Skeleton({ className, ...props }: React.ComponentProps<"div">) {
return (
@@ -7,7 +7,7 @@ function Skeleton({ className, ...props }: React.ComponentProps<"div">) {
className={cn("bg-accent animate-pulse rounded-md", className)}
{...props}
/>
- )
+ );
}
-export { Skeleton }
+export { Skeleton };