Skip to content

Commit

Permalink
Removed unused code/exports
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelschwobe committed Dec 4, 2023
1 parent e741ebc commit 3fc4056
Show file tree
Hide file tree
Showing 65 changed files with 118 additions and 216 deletions.
2 changes: 1 addition & 1 deletion app/components/button-cancel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import type { ButtonProps } from "~/components/ui/button";
import { Button } from "~/components/ui/button";
import { Icon } from "~/components/ui/icon";

export interface ButtonCancelProps
interface ButtonCancelProps
extends Omit<
ButtonProps,
"children" | "onClick" | "size" | "type" | "variant"
Expand Down
2 changes: 1 addition & 1 deletion app/components/button-column-sort.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { Button } from "~/components/ui/button";
import { Icon } from "~/components/ui/icon";
import { cn } from "~/utils/misc";

export interface ButtonColumnSortProps
interface ButtonColumnSortProps
extends Omit<
React.ComponentPropsWithoutRef<typeof Button>,
"onClick" | "size" | "type" | "variant"
Expand Down
2 changes: 1 addition & 1 deletion app/components/button-delete.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { Button } from "~/components/ui/button";
import { Icon } from "~/components/ui/icon";
import { useDoubleCheck } from "~/utils/misc";

export interface ButtonDeleteProps
interface ButtonDeleteProps
extends Omit<
React.ComponentPropsWithoutRef<typeof Button>,
"children" | "disabled" | "type" | "value"
Expand Down
2 changes: 1 addition & 1 deletion app/components/button-export.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { Icon } from "~/components/ui/icon";
import type { BookmarkExportFileExtension } from "~/utils/bookmark";
import { BOOKMARK_EXPORT_FILE_TYPE_MAP } from "~/utils/bookmark";

export interface ButtonExportProps
interface ButtonExportProps
extends Omit<
React.ComponentPropsWithoutRef<typeof Button>,
"children" | "size" | "value" | "variant"
Expand Down
2 changes: 1 addition & 1 deletion app/components/button-favorite.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { Button } from "~/components/ui/button";
import { Icon } from "~/components/ui/icon";
import { cn } from "~/utils/misc";

export interface ButtonFavoriteProps
interface ButtonFavoriteProps
extends Omit<
React.ComponentPropsWithoutRef<typeof Button>,
"children" | "type" | "value"
Expand Down
2 changes: 1 addition & 1 deletion app/components/button-first.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { forwardRef } from "react";
import { Button } from "~/components/ui/button";
import { Icon } from "~/components/ui/icon";

export interface ButtonFirstProps
interface ButtonFirstProps
extends Omit<
React.ComponentPropsWithoutRef<typeof Button>,
"children" | "type"
Expand Down
2 changes: 1 addition & 1 deletion app/components/button-last.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { forwardRef } from "react";
import { Button } from "~/components/ui/button";
import { Icon } from "~/components/ui/icon";

export interface ButtonLastProps
interface ButtonLastProps
extends Omit<
React.ComponentPropsWithoutRef<typeof Button>,
"children" | "type"
Expand Down
2 changes: 1 addition & 1 deletion app/components/button-next.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { forwardRef } from "react";
import { Button } from "~/components/ui/button";
import { Icon } from "~/components/ui/icon";

export interface ButtonNextProps
interface ButtonNextProps
extends Omit<
React.ComponentPropsWithoutRef<typeof Button>,
"children" | "type"
Expand Down
2 changes: 1 addition & 1 deletion app/components/button-page.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { forwardRef } from "react";
import { Button } from "~/components/ui/button";

export interface ButtonPageProps
interface ButtonPageProps
extends Omit<
React.ComponentPropsWithoutRef<typeof Button>,
"children" | "type"
Expand Down
2 changes: 1 addition & 1 deletion app/components/button-prev.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { forwardRef } from "react";
import { Button } from "~/components/ui/button";
import { Icon } from "~/components/ui/icon";

export interface ButtonPrevProps
interface ButtonPrevProps
extends Omit<
React.ComponentPropsWithoutRef<typeof Button>,
"children" | "type"
Expand Down
2 changes: 1 addition & 1 deletion app/components/card-latest-bookmarks.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import type { loader as loaderIndex } from "~/routes/_index";
import { cn } from "~/utils/misc";
import { USER_LOGIN_ROUTE } from "~/utils/user";

export interface CardLatestBookmarksProps
interface CardLatestBookmarksProps
extends Omit<React.ComponentPropsWithoutRef<"div">, "children"> {
/** Sets the `class` attribute. */
className?: string | undefined;
Expand Down
2 changes: 1 addition & 1 deletion app/components/card-latest-tags.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import type { loader as loaderIndex } from "~/routes/_index";
import { cn } from "~/utils/misc";
import { USER_LOGIN_ROUTE } from "~/utils/user";

export interface CardLatestTagsProps
interface CardLatestTagsProps
extends Omit<React.ComponentPropsWithoutRef<"div">, "children"> {
/** Sets the `class` attribute. */
className?: string | undefined;
Expand Down
2 changes: 1 addition & 1 deletion app/components/card-quick-bookmark.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import { LinkButton } from "~/components/ui/link-button";
import { cn } from "~/utils/misc";
import { USER_LOGIN_ROUTE, useOptionalUser } from "~/utils/user";

export interface CardQuickBookmarkProps
interface CardQuickBookmarkProps
extends Omit<React.ComponentPropsWithoutRef<"div">, "children"> {
/** Sets the `class` attribute. */
className?: string | undefined;
Expand Down
2 changes: 1 addition & 1 deletion app/components/card-quick-tag.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import { LinkButton } from "~/components/ui/link-button";
import { cn } from "~/utils/misc";
import { USER_LOGIN_ROUTE, useOptionalUser } from "~/utils/user";

export interface CardQuickTagProps
interface CardQuickTagProps
extends Omit<React.ComponentPropsWithoutRef<"div">, "children"> {
/** Sets the `class` attribute. */
className?: string | undefined;
Expand Down
4 changes: 2 additions & 2 deletions app/components/error-boundary.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@ export function MainError({ children }: { children: React.ReactNode }) {
);
}

export type StatusHandler = (info: {
type StatusHandler = (info: {
error: ErrorResponse;
params: Record<string, string | undefined>;
}) => JSX.Element | null;

export interface GeneralErrorBoundaryProps {
interface GeneralErrorBoundaryProps {
defaultStatusHandler?: StatusHandler;
statusHandlers?: Record<number, StatusHandler>;
unexpectedErrorHandler?: (error: unknown) => JSX.Element | null;
Expand Down
2 changes: 1 addition & 1 deletion app/components/form-export.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { Form } from "@remix-run/react";
import { forwardRef } from "react";
import type { BookmarkExportFileExtension } from "~/utils/bookmark";

export interface FormExportProps
interface FormExportProps
extends Omit<
React.ComponentPropsWithoutRef<typeof Form>,
"action" | "method" | "reloadDocument"
Expand Down
2 changes: 1 addition & 1 deletion app/components/form-paginate.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { Form } from "@remix-run/react";
import { forwardRef } from "react";
import { cn } from "~/utils/misc";

export interface FormPaginateProps
interface FormPaginateProps
extends Omit<
React.ComponentPropsWithoutRef<typeof Form>,
"method" | "preventScrollReset" | "replace"
Expand Down
18 changes: 9 additions & 9 deletions app/components/header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import {
useOptionalUser,
} from "~/utils/user";

export const headerNavLinkVariants = cva(
const headerNavLinkVariants = cva(
"inline-flex h-14 w-14 items-center justify-center gap-2 whitespace-nowrap border border-transparent font-medium transition-colors focus-visible:border-pink-400 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-pink-400 dark:focus-visible:border-pink-500 dark:focus-visible:ring-pink-500 sm:rounded-md",
{
variants: {
Expand All @@ -33,9 +33,9 @@ export const headerNavLinkVariants = cva(
},
);

export type HeaderNavLinkVariants = VariantProps<typeof headerNavLinkVariants>;
type HeaderNavLinkVariants = VariantProps<typeof headerNavLinkVariants>;

export interface HeaderNavLinkProps extends Omit<NavLinkProps, "className"> {
interface HeaderNavLinkProps extends Omit<NavLinkProps, "className"> {
/** Sets the content. **Required** */
children: React.ReactNode;
/** Sets the `class` attribute. */
Expand All @@ -44,7 +44,7 @@ export interface HeaderNavLinkProps extends Omit<NavLinkProps, "className"> {
iconType: IconType;
}

export const HeaderNavLink = forwardRef<
const HeaderNavLink = forwardRef<
React.ElementRef<typeof NavLink>,
HeaderNavLinkProps
>(({ children, className, iconType, to, ...props }, forwardedRef) => {
Expand All @@ -63,7 +63,7 @@ export const HeaderNavLink = forwardRef<

HeaderNavLink.displayName = "HeaderNavLink";

export interface HeaderButtonProps
interface HeaderButtonProps
extends React.ComponentPropsWithoutRef<"button">,
HeaderNavLinkVariants {
/** Sets the content. **Required** */
Expand All @@ -76,7 +76,7 @@ export interface HeaderButtonProps
type: "button" | "submit";
}

export const HeaderNavButton = forwardRef<
const HeaderNavButton = forwardRef<
React.ElementRef<"button">,
HeaderButtonProps
>(({ children, className, iconType, type, ...props }, forwardedRef) => {
Expand All @@ -95,14 +95,14 @@ export const HeaderNavButton = forwardRef<

HeaderNavButton.displayName = "HeaderNavButton";

export interface HeaderNavButtonThemeProps {
interface HeaderNavButtonThemeProps {
/** Sets the `class` attribute. */
className?: string | undefined;
/** Sets the default theme. */
userTheme?: Theme | null | undefined;
}

export const HeaderNavButtonTheme = ({
const HeaderNavButtonTheme = ({
className,
userTheme,
}: HeaderNavButtonThemeProps) => {
Expand Down Expand Up @@ -143,7 +143,7 @@ export const HeaderNavButtonTheme = ({
);
};

export interface HeaderProps
interface HeaderProps
extends Omit<React.ComponentPropsWithoutRef<"header">, "children">,
Pick<HeaderNavButtonThemeProps, "userTheme"> {
/** Sets the `class` attribute. */
Expand Down
2 changes: 1 addition & 1 deletion app/components/intro.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { forwardRef } from "react";
import { Code } from "~/components/ui/code";
import { cn } from "~/utils/misc";

export interface IntroProps
interface IntroProps
extends Omit<React.ComponentPropsWithoutRef<"div">, "children"> {
/** Sets the `class` attribute. */
className?: string | undefined;
Expand Down
2 changes: 1 addition & 1 deletion app/components/main.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { forwardRef } from "react";
import { cn } from "~/utils/misc";

export interface MainProps extends React.ComponentPropsWithoutRef<"main"> {
interface MainProps extends React.ComponentPropsWithoutRef<"main"> {
/** Sets the content. **Required** */
children: React.ReactNode;
/** Sets the `class` attribute. */
Expand Down
2 changes: 1 addition & 1 deletion app/components/search-form.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import { LinkButton } from "~/components/ui/link-button";
import { cn, getFieldError } from "~/utils/misc";
import { toSearchFormSchema } from "~/utils/misc-validation";

export interface SearchFormProps {
interface SearchFormProps {
/** Sets the `class` attribute. */
className?: string | undefined;
/** Sets the default checked radio. */
Expand Down
2 changes: 1 addition & 1 deletion app/components/search-help.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ type FormatItemsFoundByCountProps = Parameters<
typeof formatItemsFoundByCount
>[0];

export interface SearchHelpProps
interface SearchHelpProps
extends React.ComponentPropsWithoutRef<"div">,
FormatItemsFoundByCountProps {
/** Sets the content. */
Expand Down
16 changes: 8 additions & 8 deletions app/components/table-columns.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ type BookmarksStatusItem = StringifyDate<BookmarksStatusData[0]>;
// const columnHelperBookmarks = createColumnHelper<BookmarksItem>();
// const columnHelperBookmarksStatus = createColumnHelper<BookmarksStatusItem>();

export const columnSelectable = createColumnHelper<{
const columnSelectable = createColumnHelper<{
id: string;
}>().display({
id: "select",
Expand Down Expand Up @@ -68,7 +68,7 @@ export const columnSelectable = createColumnHelper<{
footer: ({ column }) => column.id,
});

export const columnCreatedAt = createColumnHelper<{
const columnCreatedAt = createColumnHelper<{
createdAt: string;
}>().accessor("createdAt", {
sortingFn: "datetime",
Expand All @@ -89,7 +89,7 @@ export const columnCreatedAt = createColumnHelper<{
footer: ({ column }) => column.id,
});

export const columnTagRelations = createColumnHelper<{
const columnTagRelations = createColumnHelper<{
_count: {
tags: number;
};
Expand All @@ -106,7 +106,7 @@ export const columnTagRelations = createColumnHelper<{
footer: ({ column }) => column.id,
});

export const columnBookmarkStatus = createColumnHelper<{
const columnBookmarkStatus = createColumnHelper<{
id: string;
_meta: { ok: boolean; status: number; statusText: string };
}>().accessor((row) => row._meta.status, {
Expand Down Expand Up @@ -135,7 +135,7 @@ export const columnBookmarkStatus = createColumnHelper<{
footer: ({ column }) => column.id,
});

export const columnBookmarkTitle = createColumnHelper<{
const columnBookmarkTitle = createColumnHelper<{
id: string;
title: string;
_meta?: { faviconSrc: string | null };
Expand Down Expand Up @@ -164,7 +164,7 @@ export const columnBookmarkTitle = createColumnHelper<{
footer: ({ column }) => column.id,
});

export const columnBookmarkUrl = createColumnHelper<{
const columnBookmarkUrl = createColumnHelper<{
id: string;
url: string;
}>().accessor("url", {
Expand All @@ -188,7 +188,7 @@ export const columnBookmarkUrl = createColumnHelper<{
footer: ({ column }) => column.id,
});

export const columnBookmarkDelete = createColumnHelper<{
const columnBookmarkDelete = createColumnHelper<{
id: string;
}>().accessor("id", {
id: "delete",
Expand All @@ -210,7 +210,7 @@ export const columnBookmarkDelete = createColumnHelper<{
footer: ({ column }) => column.id,
});

export const columnBookmarkFavorite = createColumnHelper<{
const columnBookmarkFavorite = createColumnHelper<{
id: string;
favorite: boolean;
}>().accessor("favorite", {
Expand Down
4 changes: 2 additions & 2 deletions app/components/table-selectable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,12 @@ import {
} from "~/components/ui/table";
import { cn } from "~/utils/misc";

export interface RenderProps {
interface RenderProps {
idsNotSelected: string[];
idsSelected: string[];
}

export interface TableSelectableProps<TData, TValue>
interface TableSelectableProps<TData, TValue>
extends Omit<React.ComponentPropsWithoutRef<"div">, "children"> {
/** Sets the tfoot tr content. */
children?: React.ReactNode | ((props: RenderProps) => React.ReactNode);
Expand Down
2 changes: 1 addition & 1 deletion app/components/ui/badge.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ const badgeVariants = cva(

type BadgeVariants = VariantProps<typeof badgeVariants>;

export interface BadgeProps
interface BadgeProps
extends React.ComponentPropsWithoutRef<"span">,
BadgeVariants {
/** Sets the content. **Required** */
Expand Down
Loading

0 comments on commit 3fc4056

Please sign in to comment.