mirror of
https://github.com/darksaid98/new-phone-who-dis.git
synced 2026-12-04 22:16:40 +00:00
Improve routes
This commit is contained in:
1 parent
c65108b360
commit
dbfca1461d
2 files changed
+6
-8
No files matched your search
@@ -25,7 +25,7 @@ const appsState = atom({
|
|||||||
backgroundColor: green[400],
|
backgroundColor: green[400],
|
||||||
color: green[50],
|
color: green[50],
|
||||||
path: "/phone",
|
path: "/phone",
|
||||||
Route: () => <Route exact path="/phone" component={DialerApp} />,
|
Route: () => <Route path="/phone" component={DialerApp} />,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: "CONTACTS",
|
id: "CONTACTS",
|
||||||
@@ -34,7 +34,7 @@ const appsState = atom({
|
|||||||
backgroundColor: blue[500],
|
backgroundColor: blue[500],
|
||||||
color: blue[50],
|
color: blue[50],
|
||||||
path: "/contacts",
|
path: "/contacts",
|
||||||
Route: () => <Route exact path="/contacts" component={ContactsApp} />,
|
Route: () => <Route path="/contacts" component={ContactsApp} />,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: "CALCULATOR",
|
id: "CALCULATOR",
|
||||||
@@ -43,9 +43,7 @@ const appsState = atom({
|
|||||||
backgroundColor: purple[500],
|
backgroundColor: purple[500],
|
||||||
color: grey[50],
|
color: grey[50],
|
||||||
path: "/calculator",
|
path: "/calculator",
|
||||||
Route: () => (
|
Route: () => <Route path="/calculator" component={CalculatorApp} />,
|
||||||
<Route exact path="/calculator" component={CalculatorApp} />
|
|
||||||
),
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: "SETTINGS",
|
id: "SETTINGS",
|
||||||
@@ -54,7 +52,7 @@ const appsState = atom({
|
|||||||
backgroundColor: grey[700],
|
backgroundColor: grey[700],
|
||||||
color: grey[50],
|
color: grey[50],
|
||||||
path: "/settings",
|
path: "/settings",
|
||||||
Route: () => <Route exact path="/settings" component={SettingsApp} />,
|
Route: () => <Route path="/settings" component={SettingsApp} />,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: "BANK",
|
id: "BANK",
|
||||||
@@ -63,7 +61,7 @@ const appsState = atom({
|
|||||||
backgroundColor: orange[600],
|
backgroundColor: orange[600],
|
||||||
color: orange[50],
|
color: orange[50],
|
||||||
path: "/bank",
|
path: "/bank",
|
||||||
Route: () => <Route exact path="/bank" component={BankApp} />,
|
Route: () => <Route path="/bank" component={BankApp} />,
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -11,8 +11,8 @@ export const useNuiEvent = (app, method, handler, options = {}) => {
|
|||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
const eventListener = (event) => {
|
const eventListener = (event) => {
|
||||||
const { data } = event;
|
|
||||||
if (savedHandler.current && savedHandler.current.call) {
|
if (savedHandler.current && savedHandler.current.call) {
|
||||||
|
const { data } = event;
|
||||||
savedHandler.current(data);
|
savedHandler.current(data);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in new issue
Block a user