Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Rex Dri
Rex Dri
Commits
ebe42bc4
Commit
ebe42bc4
authored
Mar 01, 2019
by
Florent Chehab
Browse files
Finish reorganizing frontend and imports are finally linted ! youpiiiii
parent
81f10fe3
Pipeline
#35760
passed with stages
Changes
87
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
frontend/src/components/form/fields/SelectField.js
View file @
ebe42bc4
...
...
@@ -6,7 +6,7 @@ import MenuItem from "@material-ui/core/MenuItem";
import
Select
from
"
@material-ui/core/Select
"
;
import
Field
from
"
./Field
"
;
import
CustomError
from
"
../../
../../utils
/CustomError
"
;
import
CustomError
from
"
../../
common
/CustomError
"
;
import
withStyles
from
"
@material-ui/core/styles/withStyles
"
;
...
...
frontend/src/components/form/fields/TextField.js
View file @
ebe42bc4
...
...
@@ -5,9 +5,9 @@ import MuiTextField from "@material-ui/core/TextField";
import
Typography
from
"
@material-ui/core/Typography
"
;
import
Field
from
"
./Field
"
;
import
isUrl
from
"
../../../
../
utils/isUrl
"
;
import
stringHasExtension
from
"
../../../
../
utils/stringHasExtension
"
;
import
CustomError
from
"
../../
../../utils
/CustomError
"
;
import
isUrl
from
"
../../../utils/isUrl
"
;
import
stringHasExtension
from
"
../../../utils/stringHasExtension
"
;
import
CustomError
from
"
../../
common
/CustomError
"
;
class
TextField
extends
Field
{
...
...
frontend/src/components/form/fields/UsefulLinksField.js
View file @
ebe42bc4
...
...
@@ -15,8 +15,8 @@ import KeyboardArrowUpIcon from "@material-ui/icons/KeyboardArrowUp";
import
Field
from
"
./Field
"
;
import
Typography
from
"
@material-ui/core/Typography
"
;
import
isUrl
from
"
../../../
../
utils/isUrl
"
;
import
CustomError
from
"
../../
../../utils
/CustomError
"
;
import
isUrl
from
"
../../../utils/isUrl
"
;
import
CustomError
from
"
../../
common
/CustomError
"
;
...
...
frontend/src/components/form/renderFieldsMixIn.js
View file @
ebe42bc4
...
...
@@ -8,8 +8,8 @@ import TextField from "./fields/TextField";
import
MultiSelectField
from
"
./fields/MultiSelectField
"
;
import
NumberField
from
"
./fields/NumberField
"
;
import
store
from
"
../../
store/index
"
;
import
{
getLatestRead
}
from
"
../../api/utils
"
;
import
store
from
"
../../
redux/store
"
;
import
{
getLatestRead
}
from
"
../../
redux/
api/utils
"
;
export
default
{
/**
...
...
frontend/src/components/map/UnivMakers.js
View file @
ebe42bc4
...
...
@@ -4,9 +4,9 @@ import { connect } from "react-redux";
import
{
Marker
,
Popup
}
from
"
react-leaflet
"
;
import
UnivPopupContent
from
"
./UnivPopupContent
"
;
import
getActions
from
"
../../api/getActions
"
;
import
getActions
from
"
../../
redux/
api/getActions
"
;
import
CustomComponentForAPI
from
"
../CustomComponentForAPI
"
;
import
CustomComponentForAPI
from
"
../
common/
CustomComponentForAPI
"
;
import
arrayOfInstancesToMap
from
"
../../utils/arrayOfInstancesToMap
"
;
...
...
frontend/src/components/map/UnivMap.js
View file @
ebe42bc4
...
...
@@ -5,7 +5,7 @@ import PropTypes from "prop-types";
import
{
Map
,
TileLayer
,
LayersControl
,
LayerGroup
}
from
"
react-leaflet
"
;
import
UnivMarkers
from
"
./UnivMakers
"
;
import
{
saveMainMapStatus
}
from
"
../../actions/map
"
;
import
{
saveMainMapStatus
}
from
"
../../
redux/
actions/map
"
;
/**
...
...
frontend/src/components/pages/PageHome.js
View file @
ebe42bc4
...
...
@@ -3,7 +3,7 @@ import PropTypes from "prop-types";
import
withStyles
from
"
@material-ui/core/styles/withStyles
"
;
import
Typography
from
"
@material-ui/core/Typography
"
;
import
Paper
from
"
@material-ui/core/Paper
"
;
import
Markdown
from
"
../
shared
/Markdown
"
;
import
Markdown
from
"
../
common
/Markdown
"
;
const
source
=
`
...
...
frontend/src/components/pages/PageUniversity.js
View file @
ebe42bc4
...
...
@@ -2,7 +2,7 @@ import React from "react";
import
PropTypes
from
"
prop-types
"
;
import
Typography
from
"
@material-ui/core/Typography
"
;
import
Paper
from
"
@material-ui/core/Paper
"
;
import
CustomComponentForAPI
from
"
../CustomComponentForAPI
"
;
import
CustomComponentForAPI
from
"
../
common/
CustomComponentForAPI
"
;
import
{
connect
}
from
"
react-redux
"
;
import
Dialog
from
"
@material-ui/core/Dialog
"
;
import
DialogActions
from
"
@material-ui/core/DialogActions
"
;
...
...
@@ -10,18 +10,18 @@ import DialogTitle from "@material-ui/core/DialogTitle";
import
Button
from
"
@material-ui/core/Button
"
;
import
UniversityTemplate
from
"
../university/UniversityTemplate
"
;
import
UnivInfoProvider
from
"
../university/
shared
/UnivInfoProvider
"
;
import
UnivInfoProvider
from
"
../university/
common
/UnivInfoProvider
"
;
import
{
NavLink
,
Redirect
}
from
"
react-router-dom
"
;
import
getActions
from
"
../../api/getActions
"
;
import
getActions
from
"
../../
redux/
api/getActions
"
;
import
{
saveUniversityBeingViewed
}
from
"
../../actions/universityPage
"
;
}
from
"
../../
redux/
actions/universityPage
"
;
...
...
frontend/src/components/search/Search.js
View file @
ebe42bc4
...
...
@@ -3,14 +3,14 @@ import PropTypes from "prop-types";
import
TextField
from
"
@material-ui/core/TextField
"
;
import
CustomComponentForAPI
from
"
../CustomComponentForAPI
"
;
import
CustomComponentForAPI
from
"
../
common/
CustomComponentForAPI
"
;
import
{
connect
}
from
"
react-redux
"
;
import
fuzzysort
from
"
fuzzysort
"
;
import
UnivList
from
"
./UnivList
"
;
import
withStyles
from
"
@material-ui/core/styles/withStyles
"
;
import
getActions
from
"
../../api/getActions
"
;
import
getActions
from
"
../../
redux/
api/getActions
"
;
/**
...
...
frontend/src/components/settings/ColorTools.js
View file @
ebe42bc4
...
...
@@ -40,12 +40,12 @@ import MuiThemeProvider from "@material-ui/core/styles/MuiThemeProvider";
import
areSameThemes
from
"
../../utils/areSameThemes
"
;
import
CustomComponentForAPI
from
"
../CustomComponentForAPI
"
;
import
CustomComponentForAPI
from
"
../
common/
CustomComponentForAPI
"
;
import
{
saveAppTheme
,
saveAppColorPicker
}
from
"
../../actions/theme
"
;
import
{
saveAppTheme
,
saveAppColorPicker
}
from
"
../../
redux/
actions/theme
"
;
import
getActions
from
"
../../api/getActions
"
;
import
getActions
from
"
../../
redux/
api/getActions
"
;
const
HUES
=
Object
.
keys
(
colors
).
slice
(
1
,
17
);
const
SHADES
=
[
900
,
800
,
700
,
600
,
500
,
400
,
300
,
200
,
100
,
50
,
"
A700
"
,
"
A400
"
,
"
A200
"
,
"
A100
"
];
...
...
frontend/src/components/university/UniversityTemplate.js
View file @
ebe42bc4
...
...
@@ -15,7 +15,7 @@ import HistoryIcon from "@material-ui/icons/History";
import
MoreHorizIcon
from
"
@material-ui/icons/MoreHoriz
"
;
import
Typography
from
"
@material-ui/core/Typography
"
;
import
CoverGallery
from
"
./CoverGallery
"
;
import
CoverGallery
from
"
./
otherComponents/
CoverGallery
"
;
import
GeneralInfoTab
from
"
./tabs/GeneralInfoTab
"
;
// import UniversityMoreTab from "./tabs/UniversityMoreTab";
...
...
@@ -24,7 +24,7 @@ import GeneralInfoTab from "./tabs/GeneralInfoTab";
import
ScholarshipsTab
from
"
./tabs/ScholarshipsTab
"
;
// import MoreTab from "./tabs/MoreTab";
import
VisibilityContext
from
"
../
shared
/VisibilityContext
"
;
import
VisibilityContext
from
"
../
common
/VisibilityContext
"
;
/**
* Component that provides information related to if the tab is selected / visible or not
...
...
frontend/src/components/
shared
/UnivContext.js
→
frontend/src/components/
university/common
/UnivContext.js
View file @
ebe42bc4
File moved
frontend/src/components/university/common/UnivInfoConsumer.js
View file @
ebe42bc4
import
React
from
"
react
"
;
import
PropTypes
from
"
prop-types
"
;
import
__pick
from
"
lodash/pick
"
;
import
UnivContext
from
"
.
./../shared
/UnivContext
"
;
import
UnivContext
from
"
./UnivContext
"
;
//import VisibilityContext from "../../shared/VisibilityContext";
class
UnivInfoConsumer
extends
React
.
PureComponent
{
...
...
frontend/src/components/university/common/UnivInfoProvider.js
View file @
ebe42bc4
...
...
@@ -2,11 +2,11 @@ import React from "react";
import
PropTypes
from
"
prop-types
"
;
import
compose
from
"
recompose/compose
"
;
import
{
connect
}
from
"
react-redux
"
;
import
UnivContext
from
"
../
../shared
/UnivContext
"
;
import
UnivContext
from
"
../
common
/UnivContext
"
;
import
CustomComponentForAPI
from
"
../../CustomComponentForAPI
"
;
import
CustomComponentForAPI
from
"
../../
common/
CustomComponentForAPI
"
;
import
getActions
from
"
../../../api/getActions
"
;
import
getActions
from
"
../../../
redux/
api/getActions
"
;
...
...
frontend/src/components/university/editors/CountryDriEditor.js
View file @
ebe42bc4
...
...
@@ -4,12 +4,12 @@ import withStyles from "@material-ui/core/styles/withStyles";
import
compose
from
"
recompose/compose
"
;
import
{
connect
}
from
"
react-redux
"
;
import
Editor
from
"
.
./shared
/Editor
"
;
import
Form
from
"
../
shared
/Form
"
;
import
editorStyle
from
"
.
./shared
/editorStyle
"
;
import
Editor
from
"
.
/common
/Editor
"
;
import
Form
from
"
../
../form
/Form
"
;
import
editorStyle
from
"
.
/common
/editorStyle
"
;
import
getMapStateToPropsForEditor
from
"
.
./shared/editorFuncti
on
s
/getMapStateToPropsForEditor
"
;
import
getMapDispatchToPropsForEditor
from
"
.
./shared/editorFuncti
on
s
/getMapDispatchToPropsForEditor
"
;
import
getMapStateToPropsForEditor
from
"
.
/comm
on/getMapStateToPropsForEditor
"
;
import
getMapDispatchToPropsForEditor
from
"
.
/comm
on/getMapDispatchToPropsForEditor
"
;
import
{
withSnackbar
}
from
"
notistack
"
;
...
...
frontend/src/components/university/editors/CountryScholarshipEditor.js
View file @
ebe42bc4
...
...
@@ -4,13 +4,12 @@ import withStyles from "@material-ui/core/styles/withStyles";
import
compose
from
"
recompose/compose
"
;
import
{
connect
}
from
"
react-redux
"
;
import
Edit
or
from
"
.
./shared/Edit
or
"
;
import
ScholarshipF
or
m
from
"
.
.
/
shared/ScholarshipF
or
m
"
;
import
editorStyle
from
"
.
./shared
/editorStyle
"
;
import
ScholarshipF
or
m
from
"
.
/common/ScholarshipF
or
m
"
;
import
Edit
or
from
"
./
common/Edit
or
"
;
import
editorStyle
from
"
.
/common
/editorStyle
"
;
import
getMapStateToPropsForEditor
from
"
../shared/editorFunctions/getMapStateToPropsForEditor
"
;
import
getMapDispatchToPropsForEditor
from
"
../shared/editorFunctions/getMapDispatchToPropsForEditor
"
;
import
getMapStateToPropsForEditor
from
"
./common/getMapStateToPropsForEditor
"
;
import
getMapDispatchToPropsForEditor
from
"
./common/getMapDispatchToPropsForEditor
"
;
import
{
withSnackbar
}
from
"
notistack
"
;
...
...
frontend/src/components/university/editors/UniversityDriEditor.js
View file @
ebe42bc4
...
...
@@ -4,12 +4,12 @@ import withStyles from "@material-ui/core/styles/withStyles";
import
compose
from
"
recompose/compose
"
;
import
{
connect
}
from
"
react-redux
"
;
import
Editor
from
"
.
./shared
/Editor
"
;
import
Form
from
"
../
shared
/Form
"
;
import
editorStyle
from
"
.
./shared
/editorStyle
"
;
import
Editor
from
"
.
/common
/Editor
"
;
import
Form
from
"
../
../form
/Form
"
;
import
editorStyle
from
"
.
/common
/editorStyle
"
;
import
getMapStateToPropsForEditor
from
"
.
./shared/editorFuncti
on
s
/getMapStateToPropsForEditor
"
;
import
getMapDispatchToPropsForEditor
from
"
.
./shared/editorFuncti
on
s
/getMapDispatchToPropsForEditor
"
;
import
getMapStateToPropsForEditor
from
"
.
/comm
on/getMapStateToPropsForEditor
"
;
import
getMapDispatchToPropsForEditor
from
"
.
/comm
on/getMapDispatchToPropsForEditor
"
;
import
{
withSnackbar
}
from
"
notistack
"
;
const
styles
=
theme
=>
({
...
...
frontend/src/components/university/editors/UniversityGeneralEditor.js
View file @
ebe42bc4
...
...
@@ -3,16 +3,16 @@ import withStyles from "@material-ui/core/styles/withStyles";
import
compose
from
"
recompose/compose
"
;
import
{
connect
}
from
"
react-redux
"
;
import
Editor
from
"
../shared/Editor
"
;
import
Form
from
"
../shared/Form
"
;
import
editorStyle
from
"
../shared/editorStyle
"
;
import
TextField
from
"
../shared/fields/TextField
"
;
import
Editor
from
"
./common/Editor
"
;
import
Form
from
"
../../form/Form
"
;
import
editorStyle
from
"
./common/editorStyle
"
;
import
getMapStateToPropsForEditor
from
"
../shared/editorFunctions/getMapStateToPropsForEditor
"
;
import
getMapDispatchToPropsForEditor
from
"
../shared/editorFunctions/getMapDispatchToPropsForEditor
"
;
import
getMapStateToPropsForEditor
from
"
./common/getMapStateToPropsForEditor
"
;
import
getMapDispatchToPropsForEditor
from
"
./common/getMapDispatchToPropsForEditor
"
;
import
{
withSnackbar
}
from
"
notistack
"
;
import
TextField
from
"
../../form/fields/TextField
"
;
const
styles
=
theme
=>
({
...
editorStyle
(
theme
)
});
...
...
frontend/src/components/university/editors/UniversityScholarshipEditor.js
View file @
ebe42bc4
...
...
@@ -3,14 +3,13 @@ import PropTypes from "prop-types";
import
withStyles
from
"
@material-ui/core/styles/withStyles
"
;
import
compose
from
"
recompose/compose
"
;
import
{
connect
}
from
"
react-redux
"
;
import
ScholarshipForm
from
"
./common/ScholarshipForm
"
;
import
Editor
from
"
../shared/Editor
"
;
import
ScholarshipForm
from
"
../shared/ScholarshipForm
"
;
import
editorStyle
from
"
../shared/editorStyle
"
;
import
Editor
from
"
./common/Editor
"
;
import
editorStyle
from
"
./common/editorStyle
"
;
import
getMapStateToPropsForEditor
from
"
../shared/editorFunctions/getMapStateToPropsForEditor
"
;
import
getMapDispatchToPropsForEditor
from
"
../shared/editorFunctions/getMapDispatchToPropsForEditor
"
;
import
getMapStateToPropsForEditor
from
"
./common/getMapStateToPropsForEditor
"
;
import
getMapDispatchToPropsForEditor
from
"
./common/getMapDispatchToPropsForEditor
"
;
import
{
withSnackbar
}
from
"
notistack
"
;
const
styles
=
theme
=>
({
...
...
frontend/src/components/university/editors/UniversitySemestersDatesEditor.js
View file @
ebe42bc4
import
React
from
"
react
"
;
import
PropTypes
from
"
prop-types
"
;
import
withStyles
from
"
@material-ui/core/styles/withStyles
"
;
import
compose
from
"
recompose/compose
"
;
import
{
connect
}
from
"
react-redux
"
;
import
Editor
from
"
../shared/Editor
"
;
import
editorStyle
from
"
../shared/editorStyle
"
;
import
DateField
from
"
../shared/fields/DateField
"
;
import
dateStrToDate
from
"
../../../utils/dateStrToDate
"
;
import
getMapStateToPropsForEditor
from
"
../shared/editorFunctions/getMapStateToPropsForEditor
"
;
import
getMapDispatchToPropsForEditor
from
"
../shared/editorFunctions/getMapDispatchToPropsForEditor
"
;
import
DateField
from
"
../../form/fields/DateField
"
;
import
Editor
from
"
./common/Editor
"
;
import
Form
from
"
../../form/Form
"
;
import
editorStyle
from
"
./common/editorStyle
"
;
import
getMapStateToPropsForEditor
from
"
./common/getMapStateToPropsForEditor
"
;
import
getMapDispatchToPropsForEditor
from
"
./common/getMapDispatchToPropsForEditor
"
;
import
CustomError
from
"
../../common/CustomError
"
;
import
Form
from
"
../shared/Form
"
;
import
{
withSnackbar
}
from
"
notistack
"
;
import
CustomError
from
"
../../../utils/CustomError
"
;
const
styles
=
theme
=>
({
...
...
Prev
1
2
3
4
5
Next
Write
Preview
Supports
Markdown
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