Skip to content

Commit

Permalink
Implemented version view
Browse files Browse the repository at this point in the history
  • Loading branch information
rmathis committed Apr 29, 2021
1 parent b407d4f commit e42c9d2
Show file tree
Hide file tree
Showing 21 changed files with 129 additions and 603 deletions.
2 changes: 2 additions & 0 deletions ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
"http-proxy-middleware": "^1.2.0",
"lodash": "^4.17.21",
"prop-types": "^15.7.2",
"query-string": "^7.0.0",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"react-infinite-scroll-component": "^6.1.0",
Expand All @@ -24,6 +25,7 @@
"reactstrap": "^8.9.0",
"sass": "^1.32.11",
"use-http": "^1.0.20",
"use-query-params": "^1.2.2",
"web-vitals": "^1.0.1"
},
"scripts": {
Expand Down
29 changes: 16 additions & 13 deletions ui/src/app/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,15 @@ import {
Redirect,
Route
} from "react-router-dom";
import { QueryParamProvider } from 'use-query-params';
import { Provider as HttpProvider } from 'use-http';

import './App.scss';
import { I18nProvider } from './i18n/context/I18n.provider';
import Footer from './core/components/Footer';
import { get_cookie } from './core/utility/get_cookie';

import Dashboard from './dashboard/container/Dashboard';
import Dashboard from './dashboard/view/Dashboard';
import Header from './core/components/Header';
import { UserProvider } from './core/user/UserContext';
import { Metadata } from './metadata/Metadata';
Expand All @@ -38,18 +39,20 @@ function App() {
<UserProvider>
<I18nProvider>
<Router>
<Header />
<main className="pad-content">
<Switch>
<Route exact path="/">
<Redirect to="/dashboard" />
</Route>
<Route path="/dashboard" component={Dashboard} />
<Route path="/metadata/:type/:id" component={Metadata} />
</Switch>
<NotificationList />
</main>
<Footer />
<QueryParamProvider ReactRouterRoute={Route}>
<Header />
<main className="pad-content">
<Switch>
<Route exact path="/">
<Redirect to="/dashboard" />
</Route>
<Route path="/dashboard" component={Dashboard} />
<Route path="/metadata/:type/:id" component={Metadata} />
</Switch>
<NotificationList />
</main>
<Footer />
</QueryParamProvider>
</Router>
</I18nProvider>
</UserProvider>
Expand Down
4 changes: 2 additions & 2 deletions ui/src/app/core/components/FormattedDate.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import React from 'react';
import { format } from 'date-fns';
import { format, parseISO } from 'date-fns';

export default function FormattedDate ({ date, time = false }) {
const formatted = React.useMemo(() => format(new Date(date), `MMM Lo, Y${time ? ' HH:mm:ss' : ''}`), [date, time]);
const formatted = React.useMemo(() => format(parseISO(date), `MMM d, Y${time ? ' HH:mm:ss' : ''}`), [date, time]);

return (<>{ formatted }</>);
}
42 changes: 0 additions & 42 deletions ui/src/app/dashboard/container/ActionsTab.js

This file was deleted.

51 changes: 0 additions & 51 deletions ui/src/app/dashboard/container/AdminTab.js

This file was deleted.

108 changes: 0 additions & 108 deletions ui/src/app/dashboard/container/Dashboard.js

This file was deleted.

2 changes: 0 additions & 2 deletions ui/src/app/dashboard/container/Dashboard.scss

This file was deleted.

62 changes: 0 additions & 62 deletions ui/src/app/dashboard/container/ProvidersTab.js

This file was deleted.

46 changes: 0 additions & 46 deletions ui/src/app/dashboard/container/SourcesTab.js

This file was deleted.

Loading

0 comments on commit e42c9d2

Please sign in to comment.