chore: adding a new index.ts file to improve the way we're exporting components (ui)

This commit is contained in:
Pablo Lara
2024-08-06 12:05:10 +02:00
parent 22ebe00cf6
commit 81bf3fc15f
15 changed files with 22 additions and 23 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
import React from "react";
import { Header } from "@/components";
import { Header } from "@/components/ui";
export default function Compliance() {
return (
+1 -1
View File
@@ -3,8 +3,8 @@
import Link from "next/link";
import { useEffect } from "react";
import { Alert, AlertDescription, AlertTitle } from "@/components";
import { RocketIcon } from "@/components/icons";
import { Alert, AlertDescription, AlertTitle } from "@/components/ui";
export default function Error({
error,
+2 -1
View File
@@ -1,8 +1,9 @@
import { Spacer } from "@nextui-org/react";
import React, { Suspense } from "react";
import { ColumnsFindings, Header, SkeletonTableFindings } from "@/components";
import { ColumnsFindings, SkeletonTableFindings } from "@/components";
import { DataTable } from "@/components/providers";
import { Header } from "@/components/ui";
export default async function Findings() {
return (
+1 -1
View File
@@ -1,6 +1,6 @@
import React from "react";
import { Header } from "@/components";
import { Header } from "@/components/ui";
export default function Integration() {
return (
+1 -1
View File
@@ -3,7 +3,7 @@ import "@/styles/globals.css";
import { Metadata, Viewport } from "next";
import React from "react";
import { Toaster } from "@/components";
import { Toaster } from "@/components/ui";
import { SidebarWrap } from "@/components/ui/sidebar";
import { fontSans } from "@/config/fonts";
import { siteConfig } from "@/config/site";
+1 -3
View File
@@ -1,6 +1,4 @@
import React from "react";
import { Header } from "@/components";
import { Header } from "@/components/ui";
export default function Home() {
return (
+1 -1
View File
@@ -2,13 +2,13 @@ import { Spacer } from "@nextui-org/react";
import { Suspense } from "react";
import { getProvider } from "@/actions";
import { Header } from "@/components";
import {
AddProviderModal,
ColumnsProviders,
DataTable,
SkeletonTableProvider,
} from "@/components/providers";
import { Header } from "@/components/ui";
export default async function Providers() {
return (
+1 -1
View File
@@ -1,6 +1,6 @@
import React from "react";
import { Header } from "@/components";
import { Header } from "@/components/ui";
export default function Services() {
return (
+1 -1
View File
@@ -1,6 +1,6 @@
import { Spacer } from "@nextui-org/react";
import { Header } from "@/components";
import { Header } from "@/components/ui";
export default async function Settings() {
return (
-8
View File
@@ -1,10 +1,2 @@
export * from "./findings/ColumnsFindings";
export * from "./findings/SkeletonTableFindings";
export * from "./ui/alert/Alert";
export * from "./ui/dialog/Dialog";
export * from "./ui/header/Header";
export * from "./ui/modal";
export * from "./ui/sidebar";
export * from "./ui/table/StatusBadge";
export * from "./ui/table/Table";
export * from "./ui/toast";
+1 -1
View File
@@ -12,7 +12,7 @@ import {
DialogTitle,
DialogTrigger,
useToast,
} from "@/components";
} from "@/components/ui";
import { ButtonAddProvider } from "./ButtonAddProvider";
import { CustomRadioProvider } from "./CustomRadioProvider";
+8
View File
@@ -0,0 +1,8 @@
export * from "./alert/Alert";
export * from "./dialog/Dialog";
export * from "./header/Header";
export * from "./modal";
export * from "./sidebar";
export * from "./table/StatusBadge";
export * from "./table/Table";
export * from "./toast";
+1 -1
View File
@@ -3,7 +3,7 @@
import { Button, useDisclosure } from "@nextui-org/react";
import React from "react";
import { Modal } from "@/components";
import { Modal } from "@/components/ui";
interface ModalWrapProps {
modalTitle: string;
+1 -1
View File
@@ -7,7 +7,7 @@ import {
ToastProvider,
ToastTitle,
ToastViewport,
} from "@/components";
} from "@/components/ui";
import { useToast } from "./use-toast";
+1 -1
View File
@@ -3,7 +3,7 @@
// Inspired by react-hot-toast library
import * as React from "react";
import type { ToastActionElement, ToastProps } from "@/components";
import type { ToastActionElement, ToastProps } from "@/components/ui";
const TOAST_LIMIT = 6;
const TOAST_REMOVE_DELAY = 1000000;