feat: make file icon in table smaller
This commit is contained in:
@@ -1,4 +1,6 @@
|
|||||||
export function DirectoryIcon() {
|
import { cn } from "@/lib/utils"
|
||||||
|
|
||||||
|
export function DirectoryIcon({ className }: { className?: string }) {
|
||||||
return (
|
return (
|
||||||
<svg
|
<svg
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
xmlns="http://www.w3.org/2000/svg"
|
||||||
@@ -6,7 +8,10 @@ export function DirectoryIcon() {
|
|||||||
height="24"
|
height="24"
|
||||||
viewBox="0 0 24 24"
|
viewBox="0 0 24 24"
|
||||||
fill="currentColor"
|
fill="currentColor"
|
||||||
className="icon icon-tabler icons-tabler-filled icon-tabler-folder text-orange-300"
|
className={cn(
|
||||||
|
"icon icon-tabler icons-tabler-filled icon-tabler-folder text-orange-300",
|
||||||
|
className,
|
||||||
|
)}
|
||||||
aria-label="Directory"
|
aria-label="Directory"
|
||||||
>
|
>
|
||||||
<title>Directory</title>
|
<title>Directory</title>
|
||||||
|
@@ -1,4 +1,6 @@
|
|||||||
export function TextFileIcon() {
|
import { cn } from "@/lib/utils"
|
||||||
|
|
||||||
|
export function TextFileIcon({ className }: { className?: string }) {
|
||||||
return (
|
return (
|
||||||
<svg
|
<svg
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
xmlns="http://www.w3.org/2000/svg"
|
||||||
@@ -6,7 +8,10 @@ export function TextFileIcon() {
|
|||||||
height="24"
|
height="24"
|
||||||
viewBox="0 0 24 24"
|
viewBox="0 0 24 24"
|
||||||
fill="currentColor"
|
fill="currentColor"
|
||||||
className="icon icon-tabler icons-tabler-filled icon-tabler-file-text text-blue-300"
|
className={cn(
|
||||||
|
"icon icon-tabler icons-tabler-filled icon-tabler-file-text text-blue-300",
|
||||||
|
className,
|
||||||
|
)}
|
||||||
>
|
>
|
||||||
<title>Text File</title>
|
<title>Text File</title>
|
||||||
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
|
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
|
||||||
|
@@ -83,7 +83,7 @@ const columns: ColumnDef<DirectoryItem>[] = [
|
|||||||
case "directory":
|
case "directory":
|
||||||
return (
|
return (
|
||||||
<div className="flex items-center gap-2">
|
<div className="flex items-center gap-2">
|
||||||
<DirectoryIcon />
|
<DirectoryIcon className="size-4" />
|
||||||
{row.original.doc.name}
|
{row.original.doc.name}
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
@@ -364,7 +364,7 @@ function NewItemRow() {
|
|||||||
function FileNameCell({ initialName }: { initialName: string }) {
|
function FileNameCell({ initialName }: { initialName: string }) {
|
||||||
return (
|
return (
|
||||||
<div className="flex items-center gap-2">
|
<div className="flex items-center gap-2">
|
||||||
<TextFileIcon />
|
<TextFileIcon className="size-4" />
|
||||||
{initialName}
|
{initialName}
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
|
Reference in New Issue
Block a user