Fakultas Ilmu Komputer UI

Commit 86b2e229 authored by Michael Wiryadinata Halim's avatar Michael Wiryadinata Halim
Browse files

Coldfix sprint 4 fix material ui theme

parent 75f44c3f
......@@ -26,5 +26,4 @@ test-report.xml
npm-debug.log*
yarn-debug.log*
yarn-error.log*
package-lock.json
/.vscode
This diff is collapsed.
......@@ -4,6 +4,7 @@ import * as ACTIONS from "./store/actions/actions";
import AuthContext from "./utils/contex";
import Routes from "./routes";
import Loader from "./component/Loader";
import { createMuiTheme, ThemeProvider } from "@material-ui/core/styles";
const ApplicationState = () => {
const [stateAuthReducer, dispatchAuthReducer] = useReducer(
......@@ -19,8 +20,10 @@ const ApplicationState = () => {
dispatchAuthReducer(ACTIONS.logout());
};
const theme = createMuiTheme();
return (
<div>
<ThemeProvider theme={theme}>
<Loader />
<AuthContext.Provider
value={{
......@@ -31,7 +34,7 @@ const ApplicationState = () => {
>
<Routes />
</AuthContext.Provider>
</div>
</ThemeProvider>
);
};
export default ApplicationState;
......@@ -5,6 +5,8 @@ import { makeStyles } from "@material-ui/core/styles";
const useStyles = makeStyles((theme) => ({
backdrop: {
zIndex: theme.zIndex.drawer + 1,
},
circular: {
color: "#6200EE",
},
}));
......@@ -13,7 +15,7 @@ const Loader = () => {
const { promiseInProgress } = usePromiseTracker();
return (
<Backdrop className={classes.backdrop} open={promiseInProgress}>
<CircularProgress color="inherit" />
<CircularProgress className={classes.circular} />
</Backdrop>
);
};
......
......@@ -14,7 +14,7 @@ import DialogContent from "@material-ui/core/DialogContent";
import DialogTitle from "@material-ui/core/DialogTitle";
import FormDonasi from "./FormDonasi";
const DetailDonasi = ({ idDonasi }) => {
const url = `${process.env.REACT_APP_BASE_URL}/program-donations/${idDonasi}`;
const url = `${process.env.REACT_APP_BASE_URL}/program-donations/${idDonasi}/`;
const [donation, error] = useFetchSingleData(url);
const [dialogOpen, setDialogOpen] = useState(false);
......
......@@ -21,7 +21,7 @@ import DialogContent from "@material-ui/core/DialogContent";
import DialogTitle from "@material-ui/core/DialogTitle";
import FormStatus from "./FormStatus";
const DetailTransaksi = ({ idTransaksi }) => {
const url = `${process.env.REACT_APP_BASE_URL}/transactions/${idTransaksi}`;
const url = `${process.env.REACT_APP_BASE_URL}/transactions/${idTransaksi}/`;
const [transaction, error] = useFetchSingleData(url);
const [dialogOpen, setDialogOpen] = useState(false);
......
......@@ -12,7 +12,7 @@ import Button from "@material-ui/core/Button";
import { Save } from "@material-ui/icons";
const FormStatus = ({ idTransaksi, defaultStatus, paymentMethod }) => {
const url = `${process.env.REACT_APP_BASE_URL}/transactions/${idTransaksi}`;
const url = `${process.env.REACT_APP_BASE_URL}/transactions/${idTransaksi}/`;
const { register, handleSubmit } = useForm({
defaultValues: {
transaction_status: defaultStatus,
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment