Skip to content

Commit

Permalink
Add prettier formater to web code
Browse files Browse the repository at this point in the history
  • Loading branch information
nandesh-dev committed Oct 18, 2024
1 parent e71f172 commit 78304b4
Show file tree
Hide file tree
Showing 22 changed files with 4,082 additions and 3,036 deletions.
36 changes: 18 additions & 18 deletions web/assets/file.tsx
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
import { CSSProperties } from "react";
import { CSSProperties } from 'react'

export function FileIcon({
className,
style,
className,
style,
}: {
className?: string;
style?: CSSProperties;
className?: string
style?: CSSProperties
}) {
return (
<svg
width="23"
height="18"
viewBox="0 0 23 18"
fill="none"
xmlns="http://www.w3.org/2000/svg"
className={className}
style={style}
>
<path d="M2.3 18C1.6675 18 1.12623 17.7799 0.6762 17.3396C0.2254 16.8986 0 16.3688 0 15.75V2.25C0 1.63125 0.2254 1.10175 0.6762 0.6615C1.12623 0.2205 1.6675 0 2.3 0H8.25125C8.55792 0 8.8504 0.0562501 9.1287 0.16875C9.40623 0.28125 9.65042 0.440625 9.86125 0.646875L11.5 2.25H20.7C21.3325 2.25 21.8741 2.4705 22.3249 2.9115C22.775 3.35175 23 3.88125 23 4.5V15.75C23 16.3688 22.775 16.8986 22.3249 17.3396C21.8741 17.7799 21.3325 18 20.7 18H2.3ZM2.3 2.25V15.75H20.7V4.5H10.5513L8.25125 2.25H2.3Z" />
</svg>
);
return (
<svg
width="23"
height="18"
viewBox="0 0 23 18"
fill="none"
xmlns="http://www.w3.org/2000/svg"
className={className}
style={style}
>
<path d="M2.3 18C1.6675 18 1.12623 17.7799 0.6762 17.3396C0.2254 16.8986 0 16.3688 0 15.75V2.25C0 1.63125 0.2254 1.10175 0.6762 0.6615C1.12623 0.2205 1.6675 0 2.3 0H8.25125C8.55792 0 8.8504 0.0562501 9.1287 0.16875C9.40623 0.28125 9.65042 0.440625 9.86125 0.646875L11.5 2.25H20.7C21.3325 2.25 21.8741 2.4705 22.3249 2.9115C22.775 3.35175 23 3.88125 23 4.5V15.75C23 16.3688 22.775 16.8986 22.3249 17.3396C21.8741 17.7799 21.3325 18 20.7 18H2.3ZM2.3 2.25V15.75H20.7V4.5H10.5513L8.25125 2.25H2.3Z" />
</svg>
)
}
38 changes: 19 additions & 19 deletions web/assets/folder.tsx
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
import { CSSProperties } from "react";
import { CSSProperties } from 'react'

export function FolderIcon({
className,
style,
className,
style,
}: {
className?: string;
style?: CSSProperties;
className?: string
style?: CSSProperties
}) {
return (
<svg
width="52"
height="38"
viewBox="0 0 52 38"
fill="none"
xmlns="http://www.w3.org/2000/svg"
className={className}
style={style}
>
<path d="M43.207 0.128418H9.20703C6.99789 0.128418 5.20703 1.91928 5.20703 4.12842V9.25683C5.20703 9.25683 21.4979 9.12842 23.707 9.12842C23.707 9.12842 26.7317 5.7363 27.7244 4.7436C28.7171 3.75089 30.9298 2.99819 32.4215 2.99819L47.0174 2.99819C46.7092 0.95483 45.4162 0.128418 43.207 0.128418Z" />
<path d="M23.7001 13.1319C24.8351 13.1319 25.9168 12.6497 26.6754 11.8054L29.8014 8.32649C30.5601 7.48222 31.6417 7 32.7767 7H47.3554C49.8008 7 51.6738 9.17486 51.3112 11.5932L47.8619 34.5932C47.5682 36.5514 45.8862 38 43.9061 38H7.07635C5.08953 38 3.40385 36.5417 3.11797 34.5756L0.665299 17.7074C0.314465 15.2946 2.18546 13.1319 4.62367 13.1319H23.7001Z" />
</svg>
);
return (
<svg
width="52"
height="38"
viewBox="0 0 52 38"
fill="none"
xmlns="http://www.w3.org/2000/svg"
className={className}
style={style}
>
<path d="M43.207 0.128418H9.20703C6.99789 0.128418 5.20703 1.91928 5.20703 4.12842V9.25683C5.20703 9.25683 21.4979 9.12842 23.707 9.12842C23.707 9.12842 26.7317 5.7363 27.7244 4.7436C28.7171 3.75089 30.9298 2.99819 32.4215 2.99819L47.0174 2.99819C46.7092 0.95483 45.4162 0.128418 43.207 0.128418Z" />
<path d="M23.7001 13.1319C24.8351 13.1319 25.9168 12.6497 26.6754 11.8054L29.8014 8.32649C30.5601 7.48222 31.6417 7 32.7767 7H47.3554C49.8008 7 51.6738 9.17486 51.3112 11.5932L47.8619 34.5932C47.5682 36.5514 45.8862 38 43.9061 38H7.07635C5.08953 38 3.40385 36.5417 3.11797 34.5756L0.665299 17.7074C0.314465 15.2946 2.18546 13.1319 4.62367 13.1319H23.7001Z" />
</svg>
)
}
36 changes: 18 additions & 18 deletions web/assets/home.tsx
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
import { CSSProperties } from "react";
import { CSSProperties } from 'react'

export function HomeIcon({
className,
style,
className,
style,
}: {
className?: string;
style?: CSSProperties;
className?: string
style?: CSSProperties
}) {
return (
<svg
width="20"
height="22"
viewBox="0 0 20 22"
fill="none"
xmlns="http://www.w3.org/2000/svg"
className={className}
style={style}
>
<path d="M2.5 19.4857H6.25V11.9429H13.75V19.4857H17.5V8.17143L10 2.51429L2.5 8.17143V19.4857ZM2.5 22C1.8125 22 1.22417 21.754 0.735 21.2621C0.245 20.7693 0 20.1771 0 19.4857V8.17143C0 7.77333 0.0887498 7.39619 0.26625 7.04C0.442916 6.68381 0.6875 6.39048 1 6.16L8.5 0.502857C8.72917 0.335238 8.96875 0.209524 9.21875 0.125714C9.46875 0.0419046 9.72917 0 10 0C10.2708 0 10.5312 0.0419046 10.7812 0.125714C11.0313 0.209524 11.2708 0.335238 11.5 0.502857L19 6.16C19.3125 6.39048 19.5575 6.68381 19.735 7.04C19.9117 7.39619 20 7.77333 20 8.17143V19.4857C20 20.1771 19.7554 20.7693 19.2663 21.2621C18.7763 21.754 18.1875 22 17.5 22H11.25V14.4571H8.75V22H2.5Z" />
</svg>
);
return (
<svg
width="20"
height="22"
viewBox="0 0 20 22"
fill="none"
xmlns="http://www.w3.org/2000/svg"
className={className}
style={style}
>
<path d="M2.5 19.4857H6.25V11.9429H13.75V19.4857H17.5V8.17143L10 2.51429L2.5 8.17143V19.4857ZM2.5 22C1.8125 22 1.22417 21.754 0.735 21.2621C0.245 20.7693 0 20.1771 0 19.4857V8.17143C0 7.77333 0.0887498 7.39619 0.26625 7.04C0.442916 6.68381 0.6875 6.39048 1 6.16L8.5 0.502857C8.72917 0.335238 8.96875 0.209524 9.21875 0.125714C9.46875 0.0419046 9.72917 0 10 0C10.2708 0 10.5312 0.0419046 10.7812 0.125714C11.0313 0.209524 11.2708 0.335238 11.5 0.502857L19 6.16C19.3125 6.39048 19.5575 6.68381 19.735 7.04C19.9117 7.39619 20 7.77333 20 8.17143V19.4857C20 20.1771 19.7554 20.7693 19.2663 21.2621C18.7763 21.754 18.1875 22 17.5 22H11.25V14.4571H8.75V22H2.5Z" />
</svg>
)
}
8 changes: 4 additions & 4 deletions web/assets/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
export * from "./home";
export * from "./file";
export * from "./folder";
export * from "./search";
export * from './home'
export * from './file'
export * from './folder'
export * from './search'
36 changes: 18 additions & 18 deletions web/assets/search.tsx
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
import { CSSProperties } from "react";
import { CSSProperties } from 'react'

export function SearchIcon({
className,
style,
className,
style,
}: {
className?: string;
style?: CSSProperties;
className?: string
style?: CSSProperties
}) {
return (
<svg
width="19"
height="19"
viewBox="0 0 19 19"
fill="none"
xmlns="http://www.w3.org/2000/svg"
className={className}
style={style}
>
<path d="M13.2467 12.2936H12.4126L12.117 12.0085C13.384 10.5303 14.0386 8.51366 13.6796 6.37032C13.1834 3.4351 10.7338 1.09115 7.7775 0.732163C3.31132 0.183129 -0.447455 3.9419 0.101578 8.40808C0.460562 11.3644 2.80452 13.814 5.73974 14.3102C7.88308 14.6692 9.89972 14.0146 11.3779 12.7476L11.663 13.0432V13.8773L16.1503 18.3646C16.5832 18.7975 17.2906 18.7975 17.7235 18.3646C18.1563 17.9317 18.1563 17.2243 17.7235 16.7914L13.2467 12.2936ZM6.91171 12.2936C4.28268 12.2936 2.16046 10.1713 2.16046 7.5423C2.16046 4.91327 4.28268 2.79104 6.91171 2.79104C9.54074 2.79104 11.663 4.91327 11.663 7.5423C11.663 10.1713 9.54074 12.2936 6.91171 12.2936Z" />
</svg>
);
return (
<svg
width="19"
height="19"
viewBox="0 0 19 19"
fill="none"
xmlns="http://www.w3.org/2000/svg"
className={className}
style={style}
>
<path d="M13.2467 12.2936H12.4126L12.117 12.0085C13.384 10.5303 14.0386 8.51366 13.6796 6.37032C13.1834 3.4351 10.7338 1.09115 7.7775 0.732163C3.31132 0.183129 -0.447455 3.9419 0.101578 8.40808C0.460562 11.3644 2.80452 13.814 5.73974 14.3102C7.88308 14.6692 9.89972 14.0146 11.3779 12.7476L11.663 13.0432V13.8773L16.1503 18.3646C16.5832 18.7975 17.2906 18.7975 17.7235 18.3646C18.1563 17.9317 18.1563 17.2243 17.7235 16.7914L13.2467 12.2936ZM6.91171 12.2936C4.28268 12.2936 2.16046 10.1713 2.16046 7.5423C2.16046 4.91327 4.28268 2.79104 6.91171 2.79104C9.54074 2.79104 11.663 4.91327 11.663 7.5423C11.663 10.1713 9.54074 12.2936 6.91171 12.2936Z" />
</svg>
)
}
40 changes: 20 additions & 20 deletions web/eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,24 +5,24 @@ import reactRefresh from 'eslint-plugin-react-refresh'
import tseslint from 'typescript-eslint'

export default tseslint.config(
{ ignores: ['dist'] },
{
extends: [js.configs.recommended, ...tseslint.configs.recommended],
files: ['**/*.{ts,tsx}'],
languageOptions: {
ecmaVersion: 2020,
globals: globals.browser,
},
plugins: {
'react-hooks': reactHooks,
'react-refresh': reactRefresh,
},
rules: {
...reactHooks.configs.recommended.rules,
'react-refresh/only-export-components': [
'warn',
{ allowConstantExport: true },
],
},
},
{ ignores: ['dist'] },
{
extends: [js.configs.recommended, ...tseslint.configs.recommended],
files: ['**/*.{ts,tsx}'],
languageOptions: {
ecmaVersion: 2020,
globals: globals.browser,
},
plugins: {
'react-hooks': reactHooks,
'react-refresh': reactRefresh,
},
rules: {
...reactHooks.configs.recommended.rules,
'react-refresh/only-export-components': [
'warn',
{ allowConstantExport: true },
],
},
}
)
29 changes: 16 additions & 13 deletions web/index.html
Original file line number Diff line number Diff line change
@@ -1,16 +1,19 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Sora:[email protected]&display=swap" rel="stylesheet">
<title>Subtle</title>
</head>
<body>
<div id="root"></div>
<script type="module" src="/src/main.tsx"></script>
</body>
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link
href="https://fonts.googleapis.com/css2?family=Sora:[email protected]&display=swap"
rel="stylesheet"
/>
<title>Subtle</title>
</head>
<body>
<div id="root"></div>
<script type="module" src="/src/main.tsx"></script>
</body>
</html>
66 changes: 34 additions & 32 deletions web/package.json
Original file line number Diff line number Diff line change
@@ -1,34 +1,36 @@
{
"name": "web",
"private": true,
"version": "0.0.0",
"type": "module",
"scripts": {
"dev": "vite",
"build": "tsc -b && vite build",
"lint": "eslint .",
"preview": "vite preview"
},
"dependencies": {
"react": "^18.3.1",
"react-dom": "^18.3.1",
"react-responsive": "^10.0.0",
"react-router-dom": "^6.26.2"
},
"devDependencies": {
"@eslint/js": "^9.11.1",
"@types/react": "^18.3.10",
"@types/react-dom": "^18.3.0",
"@vitejs/plugin-react": "^4.3.2",
"autoprefixer": "^10.4.20",
"eslint": "^9.11.1",
"eslint-plugin-react-hooks": "^5.1.0-rc.0",
"eslint-plugin-react-refresh": "^0.4.12",
"globals": "^15.9.0",
"postcss": "^8.4.47",
"tailwindcss": "^3.4.13",
"typescript": "^5.5.3",
"typescript-eslint": "^8.7.0",
"vite": "^5.4.8"
}
"name": "web",
"private": true,
"version": "0.0.0",
"type": "module",
"scripts": {
"dev": "vite",
"build": "tsc -b && vite build",
"lint": "eslint .",
"preview": "vite preview"
},
"dependencies": {
"react": "^18.3.1",
"react-dom": "^18.3.1",
"react-responsive": "^10.0.0",
"react-router-dom": "^6.26.2"
},
"devDependencies": {
"@eslint/js": "^9.11.1",
"@types/react": "^18.3.10",
"@types/react-dom": "^18.3.0",
"@vitejs/plugin-react": "^4.3.2",
"autoprefixer": "^10.4.20",
"eslint": "^9.11.1",
"eslint-plugin-react-hooks": "^5.1.0-rc.0",
"eslint-plugin-react-refresh": "^0.4.12",
"globals": "^15.9.0",
"postcss": "^8.4.47",
"prettier": "^3.3.3",
"prettier-plugin-tailwindcss": "^0.6.8",
"tailwindcss": "^3.4.13",
"typescript": "^5.5.3",
"typescript-eslint": "^8.7.0",
"vite": "^5.4.8"
}
}
Loading

0 comments on commit 78304b4

Please sign in to comment.