-
Notifications
You must be signed in to change notification settings - Fork 130
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
06a70f8
commit 7e5b26b
Showing
13 changed files
with
528 additions
and
440 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,70 +1,74 @@ | ||
{ | ||
"homepage": "https://horizon-ui.com/horizon-ui-chakra-ts", | ||
"name": "horizon-ui-chakra-typescript", | ||
"version": "1.1.0", | ||
"private": true, | ||
"dependencies": { | ||
"@chakra-ui/icons": "^1.1.5", | ||
"@chakra-ui/react": "1.8.8", | ||
"@chakra-ui/system": "^1.12.1", | ||
"@chakra-ui/theme-tools": "^1.3.6", | ||
"@emotion/cache": "^11.7.1", | ||
"@emotion/react": "^11.4.1", | ||
"@emotion/styled": "^11.3.0", | ||
"@tanstack/react-table": "^8.5.13", | ||
"@testing-library/jest-dom": "^5.14.1", | ||
"@testing-library/react": "^11.2.7", | ||
"@testing-library/user-event": "^12.8.3", | ||
"@types/jest": "^25.2.3", | ||
"@types/node": "^12.20.55", | ||
"@types/react": "^18.0.15", | ||
"@types/react-dom": "^18.0.6", | ||
"apexcharts": "^3.35.2", | ||
"framer-motion": "^4.1.17", | ||
"react": "^17.0.2", | ||
"react-apexcharts": "^1.4.0", | ||
"react-calendar": "^3.7.0", | ||
"react-custom-scrollbars-2": "^4.2.1", | ||
"react-dom": "17.0.2", | ||
"react-dropzone": "^12.0.4", | ||
"react-icons": "^4.3.1", | ||
"react-is": "^18.0.0", | ||
"react-router-dom": "^5.3.0", | ||
"react-scripts": "5.0.0", | ||
"stylis": "^4.1.1", | ||
"stylis-plugin-rtl": "2.0.2", | ||
"typescript": "^4.7.4", | ||
"web-vitals": "^1.1.2" | ||
}, | ||
"scripts": { | ||
"start": "react-scripts start", | ||
"build": "react-scripts build", | ||
"test": "react-scripts test", | ||
"eject": "react-scripts eject", | ||
"predeploy": "npm run build", | ||
"deploy": "gh-pages -d build" | ||
}, | ||
"eslintConfig": { | ||
"extends": [ | ||
"react-app", | ||
"react-app/jest" | ||
] | ||
}, | ||
"browserslist": { | ||
"production": [ | ||
">0.2%", | ||
"not dead", | ||
"not op_mini all" | ||
], | ||
"development": [ | ||
"last 1 chrome version", | ||
"last 1 firefox version", | ||
"last 1 safari version" | ||
] | ||
}, | ||
"devDependencies": { | ||
"@types/react-calendar": "^3.5.2", | ||
"@types/react-router-dom": "^5.3.3", | ||
"gh-pages": "^3.2.3" | ||
} | ||
"name": "horizon-ui-chakra-typescript", | ||
"version": "2.0.0", | ||
"private": true, | ||
"dependencies": { | ||
"@babel/preset-react": "^7.18.6", | ||
"@chakra-ui/icons": "^2.0.19", | ||
"@chakra-ui/react": "2.6.1", | ||
"@chakra-ui/system": "2.5.7", | ||
"@chakra-ui/theme-tools": "^1.3.6", | ||
"@emotion/cache": "^11.12.0", | ||
"@emotion/react": "^11.12.0", | ||
"@emotion/styled": "^11.12.0", | ||
"@tanstack/react-table": "^8.19.3", | ||
"@testing-library/jest-dom": "^6.4.6", | ||
"@testing-library/react": "^16.0.0", | ||
"@testing-library/user-event": "^14.5.2", | ||
"@types/jest": "^25.2.3", | ||
"@types/node": "^12.20.55", | ||
"@types/react": "^18.0.15", | ||
"@types/react-dom": "^18.0.6", | ||
"apexcharts": "3.50.0", | ||
"framer-motion": "^11.3.7", | ||
"npm-force-resolutions": "^0.0.10", | ||
"react": "18.3.1", | ||
"react-apexcharts": "1.4.1", | ||
"react-calendar": "^5.0.0", | ||
"react-custom-scrollbars-2": "^4.5.0", | ||
"react-dom": "18.3.1", | ||
"react-dropzone": "^14.2.3", | ||
"react-icons": "^5.2.1", | ||
"react-is": "^18.3.1", | ||
"react-router-dom": "^6.25.1", | ||
"react-scripts": "^5.0.0", | ||
"stylis": "^4.1.1", | ||
"stylis-plugin-rtl": "2.0.2", | ||
"typescript": "^4.7.4", | ||
"web-vitals": "^1.1.2" | ||
}, | ||
"scripts": { | ||
"start": "react-scripts start", | ||
"build": "react-scripts build", | ||
"test": "react-scripts test", | ||
"eject": "react-scripts eject", | ||
"predeploy": "npm run build", | ||
"deploy": "gh-pages -d build", | ||
"preinstall": "npx npm-force-resolutions" | ||
}, | ||
"eslintConfig": { | ||
"extends": [ | ||
"react-app", | ||
"react-app/jest" | ||
] | ||
}, | ||
"resolutions": { | ||
"react-error-overlay": "6.0.9" | ||
}, | ||
"browserslist": { | ||
"production": [ | ||
">0.2%", | ||
"not dead", | ||
"not op_mini all" | ||
], | ||
"development": [ | ||
"last 1 chrome version", | ||
"last 1 firefox version", | ||
"last 1 safari version" | ||
] | ||
}, | ||
"devDependencies": { | ||
"@types/react-calendar": "^3.5.2", | ||
"@types/react-router-dom": "^5.3.3" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
module.exports = { | ||
trailingComma: 'all', | ||
singleQuote: true, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
import './assets/css/App.css'; | ||
import { Routes, Route, Navigate } from 'react-router-dom'; | ||
import AuthLayout from './layouts/auth'; | ||
import AdminLayout from './layouts/admin'; | ||
import RTLLayout from './layouts/rtl'; | ||
import React from 'react'; | ||
import theme from 'theme/theme'; | ||
import { ChakraProvider } from '@chakra-ui/react'; | ||
import initialTheme from './theme/theme'; // { themeGreen } | ||
import { useState } from 'react'; | ||
|
||
export default function Main() { | ||
const [currentTheme, setCurrentTheme] = useState(initialTheme); | ||
return ( | ||
<ChakraProvider theme={theme}> | ||
<React.StrictMode> | ||
<Routes> | ||
<Route path="auth/*" element={<AuthLayout />} /> | ||
<Route | ||
path="admin/*" | ||
element={ | ||
<AdminLayout theme={currentTheme} setTheme={setCurrentTheme} /> | ||
} | ||
/> | ||
<Route | ||
path="rtl/*" | ||
element={ | ||
<RTLLayout theme={currentTheme} setTheme={setCurrentTheme} /> | ||
} | ||
/> | ||
<Route path="/" element={<Navigate to="/admin" replace />} /> | ||
</Routes> | ||
</React.StrictMode> | ||
</ChakraProvider> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,14 @@ | ||
import React from 'react'; | ||
import ReactDOM from 'react-dom'; | ||
import ReactDOM from 'react-dom/client'; | ||
import { BrowserRouter } from 'react-router-dom'; | ||
import './assets/css/App.css'; | ||
import { HashRouter, Route, Switch, Redirect } from 'react-router-dom'; | ||
import AuthLayout from './layouts/auth'; | ||
import AdminLayout from './layouts/admin'; | ||
import RTLLayout from './layouts/rtl'; | ||
import { ChakraProvider } from '@chakra-ui/react'; | ||
import theme from './theme/theme'; | ||
|
||
ReactDOM.render( | ||
<ChakraProvider theme={theme}> | ||
<React.StrictMode> | ||
<HashRouter> | ||
<Switch> | ||
<Route path={`/auth`} component={AuthLayout} /> | ||
<Route path={`/admin`} component={AdminLayout} /> | ||
<Route path={`/rtl`} component={RTLLayout} /> | ||
<Redirect from='/' to='/admin' /> | ||
</Switch> | ||
</HashRouter> | ||
</React.StrictMode> | ||
</ChakraProvider>, | ||
document.getElementById('root') | ||
import App from './App'; | ||
|
||
const root = ReactDOM.createRoot(document.getElementById('root')); | ||
|
||
root.render( | ||
<BrowserRouter> | ||
<App /> | ||
</BrowserRouter>, | ||
); |
Oops, something went wrong.