Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
Tia-dev
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Dida Adams Arizona
Tia-dev
Commits
87848a42
Commit
87848a42
authored
Aug 09, 2020
by
Deni Rinaldi
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'deni-dev(pc)' into 'master'
profile1 See merge request
!22
parents
f5525d3e
e99a9640
Changes
3
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
138 additions
and
221 deletions
+138
-221
Index.js
src/Utils/Index.js
+48
-18
Profile.js
src/container/Profile.js
+67
-185
homeRoutes.js
src/router/homeRoutes.js
+23
-18
No files found.
src/Utils/Index.js
View file @
87848a42
import
React
from
'react'
;
import
React
,
{
useState
,
useEffect
}
from
'react'
;
import
Menu
from
'@material-ui/core/Menu'
;
import
MenuItem
from
'@material-ui/core/MenuItem'
;
import
{
makeStyles
}
from
'@material-ui/core/styles'
;
...
...
@@ -6,6 +6,7 @@ import Fade from '@material-ui/core/Fade';
import
Grid
from
'@material-ui/core/Grid'
;
import
{
Typography
,
Avatar
}
from
'@material-ui/core'
;
import
Images
from
'../assets/Images'
;
import
{
Link
,
useRouteMatch
}
from
'react-router-dom'
;
const
useStyles
=
makeStyles
({
avatar
:
{
...
...
@@ -32,6 +33,8 @@ function FadeMenu() {
const
classes
=
useStyles
();
let
{
path
,
url
}
=
useRouteMatch
();
return
(
<
div
>
<
Grid
container
justify
=
"center"
alignItems
=
"center"
>
...
...
@@ -58,8 +61,10 @@ function FadeMenu() {
<
/MenuItem
>
<
MenuItem
onClick
=
{
handleClose
}
>
<
div
style
=
{{
display
:
'flex'
,
padding
:
10
}}
>
<
Link
to
=
{
'/home/profile'
}
>
<
img
src
=
{
Images
.
setting
}
style
=
{{
height
:
20
,
width
:
20
,
marginRight
:
20
}}
/
>
<
Typography
>
Settings
<
/Typography
>
<
/Link
>
<
/div
>
<
/MenuItem
>
<
MenuItem
onClick
=
{
handleClose
}
>
...
...
@@ -80,24 +85,49 @@ const footerStyle = {
// borderTop: "1px solid #E7E7E7",
textAlign
:
"center"
,
padding
:
"20px"
,
left
:
"0"
,
bottom
:
"0"
,
left
:
0
,
bottom
:
0
,
right
:
0
,
height
:
"80px"
,
width
:
"100%"
};
};
const
phantomStyle
=
{
const
phantomStyle
=
{
display
:
"block"
,
};
};
function
Footer
({
children
})
{
function
Footer
({
children
})
{
return
(
<
div
>
{
/* <div style={phantomStyle} /> */
}
<
div
style
=
{
footerStyle
}
>
{
children
}
<
/div
>
<
/div
>
);
}
function
getWindowDimensions
()
{
const
{
innerWidth
:
width
,
innerHeight
:
height
}
=
window
;
return
{
width
,
height
};
}
function
UseWindowDimensions
()
{
const
[
windowDimensions
,
setWindowDimensions
]
=
useState
(
getWindowDimensions
()
);
useEffect
(()
=>
{
function
handleResize
()
{
setWindowDimensions
(
getWindowDimensions
());
}
window
.
addEventListener
(
"resize"
,
handleResize
);
return
()
=>
window
.
removeEventListener
(
"resize"
,
handleResize
);
},
[]);
return
windowDimensions
;
}
export
{
FadeMenu
,
Footer
};
\ No newline at end of file
export
{
FadeMenu
,
Footer
,
UseWindowDimensions
};
\ No newline at end of file
src/container/Profile.js
View file @
87848a42
This diff is collapsed.
Click to expand it.
src/router/homeRoutes.js
View file @
87848a42
...
...
@@ -5,6 +5,7 @@ import ApprovalMatrix from '../container/ApprovalMatrix'
import
BudgetTahunan
from
'../container/BudgetTahunan'
;
import
HomePage
from
'../container/HomePage'
;
import
BalanceSheet
from
'../container/BudgetTahunan/BalanceSheet'
;
import
Profile
from
'../container/Profile'
;
const
routes
=
[
{
...
...
@@ -23,7 +24,11 @@ const routes = [
path
:
"/home/budget-tahunan"
,
main
:
BalanceSheet
},
{
path
:
"/home/profile"
,
main
:
Profile
},
];
];
export
default
routes
;
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment