Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Self test server #59

Open
wants to merge 69 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
69 commits
Select commit Hold shift + click to select a range
89e149c
Create note
JiNoSis Oct 8, 2020
a6e731e
Delete note
JiNoSis Oct 8, 2020
853f58c
Create no_check
JiNoSis Oct 8, 2020
1d24a83
Create Boom_Check
khanadech007 Oct 8, 2020
378084a
Create no2
JiNoSis Oct 8, 2020
180ba77
Create peth
Wasu-Anu Oct 8, 2020
05f6bd2
Delete Boom_Check
JiNoSis Oct 8, 2020
8da073e
Delete no2
JiNoSis Oct 8, 2020
2885d9c
Delete no_check
JiNoSis Oct 8, 2020
78b992a
Delete peth
JiNoSis Oct 8, 2020
145b410
Create package-lock.json
JiNoSis Oct 8, 2020
f26265e
Update package.json
JiNoSis Oct 8, 2020
dff05a5
Update App.js
kingdom1447 Oct 9, 2020
07a8ff7
Update Header.js
JiNoSis Oct 13, 2020
3696348
Create Header_old.js
JiNoSis Oct 13, 2020
edc1629
Update Sidebar.js
JiNoSis Oct 13, 2020
66b9939
Create Sidebar_old.js
JiNoSis Oct 13, 2020
59304dc
Merge branch 'master' of https://github.com/JiNoSis/react-reduction
JiNoSis Oct 13, 2020
5741edc
Create peth_laptop
Wasu-Anu Oct 14, 2020
71a485c
Create debug.log
kingdom1447 Oct 14, 2020
81795b4
Create Sidebar_Teacher.js
kingdom1447 Oct 14, 2020
d41dbee
Merge branch 'master' of https://github.com/JiNoSis/react-reduction
Wasu-Anu Oct 14, 2020
b73638e
Delete peth_laptop
Wasu-Anu Oct 14, 2020
65f9c4f
Create FormPage_copy.js
kingdom1447 Oct 14, 2020
61b7c5f
Update FormPage.js
kingdom1447 Oct 14, 2020
64d4184
Update Sidebar.js
kingdom1447 Oct 14, 2020
c1f615b
Update App.js
kingdom1447 Oct 14, 2020
5d0702a
Update Sidebar.js
kingdom1447 Oct 14, 2020
dfaf031
Create SuggestPage.js
kingdom1447 Oct 14, 2020
5d5df21
Update App.js
kingdom1447 Oct 14, 2020
35c2ad3
Update SuggestPage.js
kingdom1447 Oct 14, 2020
9e42747
Update FormPage.js
kingdom1447 Oct 14, 2020
cc45f30
Update SuggestPage.js
kingdom1447 Oct 14, 2020
f8e6bda
Update Sidebar.js
Wasu-Anu Oct 14, 2020
7b8fbe8
Update debug.log
Wasu-Anu Oct 14, 2020
6c0877f
Update Sidebar_Teacher.js
kingdom1447 Oct 14, 2020
d6979e2
Update Sidebar.js
kingdom1447 Oct 14, 2020
b8eef29
Update Sidebar_Teacher.js
kingdom1447 Oct 14, 2020
76ad7b5
Create Sidebar_Default.js
kingdom1447 Oct 14, 2020
2081e81
Update App.js
kingdom1447 Oct 15, 2020
7d8d44e
Update Sidebar.js
kingdom1447 Oct 15, 2020
6c87856
Delete Sidebar_Default.js
kingdom1447 Oct 15, 2020
707c387
Create Sidebar_Student.js
kingdom1447 Oct 15, 2020
1351454
Create CourseSearchPage.js
kingdom1447 Oct 15, 2020
aaaf819
Update FormPage.js
kingdom1447 Oct 15, 2020
1bc6f1c
Delete FormPage_copy.js
kingdom1447 Oct 15, 2020
777c816
Create InsSearchPage.js
kingdom1447 Oct 15, 2020
8eca1d2
Create RequestPage.js
kingdom1447 Oct 15, 2020
6d7ae01
Create StuSearchPage.js
kingdom1447 Oct 15, 2020
cd0df28
Update SuggestPage.js
kingdom1447 Oct 15, 2020
9fa4e28
Update Sidebar.js
kingdom1447 Oct 15, 2020
25e9dc3
Update App.js
kingdom1447 Oct 16, 2020
8f88fae
Update Sidebar.js
kingdom1447 Oct 16, 2020
afc9ac6
Create AcaCalenderPage.js
kingdom1447 Oct 16, 2020
9239a31
Create FAQsPage.js
kingdom1447 Oct 16, 2020
30b290f
Create NewsBoardPage.js
kingdom1447 Oct 16, 2020
8d1b360
Update App.js
kingdom1447 Oct 16, 2020
036a503
Update App.js
Wasu-Anu Oct 20, 2020
317f462
Update Sidebar.js
Wasu-Anu Oct 20, 2020
07c64d9
Create Sidebar_default.js
Wasu-Anu Oct 20, 2020
bb2454b
Delete Sidebar_Student.js
Wasu-Anu Oct 20, 2020
4e98fd2
Create GPAPage.js
Wasu-Anu Oct 20, 2020
2089a25
Create ProfilePage.js
khanadech007 Oct 22, 2020
2ab4e94
Update ProfilePage.js
khanadech007 Oct 24, 2020
2eb7c98
Update Sidebar_Teacher.js
khanadech007 Oct 24, 2020
4f3dae5
Update Sidebar.js
khanadech007 Oct 24, 2020
14fb071
Create Happy.gif
khanadech007 Oct 24, 2020
a038b86
Update App.js
khanadech007 Oct 24, 2020
aa4b1dd
Update ProfilePage.js
khanadech007 Nov 1, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions debug.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[1009/151708.453:ERROR:directory_reader_win.cc(43)] FindFirstFile: The system cannot find the path specified. (0x3)
[1014/202622.802:ERROR:directory_reader_win.cc(43)] FindFirstFile: The system cannot find the path specified. (0x3)
26,091 changes: 26,091 additions & 0 deletions package-lock.json

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,8 @@
"stylelint-config-recommended-scss": "^3.2.0",
"stylelint-config-standard": "^18.2.0",
"stylelint-order": "^0.8.1",
"stylelint-scss": "^3.1.3"
"stylelint-scss": "^3.1.3",
"typescript": "^4.0.3"
},
"scripts": {
"start": "react-scripts start",
Expand Down
28 changes: 22 additions & 6 deletions src/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,16 @@ const ProgressPage = React.lazy(() => import('pages/ProgressPage'));
const TablePage = React.lazy(() => import('pages/TablePage'));
const TypographyPage = React.lazy(() => import('pages/TypographyPage'));
const WidgetPage = React.lazy(() => import('pages/WidgetPage'));
const SuggestPage = React.lazy(() => import('pages/SuggestPage'));
const CourseSearchPage = React.lazy(() => import('pages/CourseSearchPage'));
const RequestPage = React.lazy(() => import('pages/RequestPage'));
const StuSearchPage = React.lazy(() => import('pages/StuSearchPage'));
const InsSearchPage = React.lazy(() => import('pages/InsSearchPage'));
const NewsBoardPage = React.lazy(() => import('pages/NewsBoardPage'));
const FAQsPage = React.lazy(() => import('pages/FAQsPage'));
const AcaCalenderPage = React.lazy(() => import('pages/AcaCalenderPage'));
const GPAPage = React.lazy(() => import('pages/GPAPage'));
const ProfilePage = React.lazy(() => import('pages/ProfilePage'));

const getBasename = () => {
return `/${process.env.PUBLIC_URL.split('/').pop()}`;
Expand Down Expand Up @@ -54,7 +64,7 @@ class App extends React.Component {

<MainLayout breakpoint={this.props.breakpoint}>
<React.Suspense fallback={<PageSpinner />}>
<Route exact path="/" component={DashboardPage} />
<Route exact path="/" component={NewsBoardPage} />
<Route exact path="/login-modal" component={AuthModalPage} />
<Route exact path="/buttons" component={ButtonPage} />
<Route exact path="/cards" component={CardPage} />
Expand All @@ -63,17 +73,23 @@ class App extends React.Component {
<Route exact path="/alerts" component={AlertPage} />
<Route exact path="/tables" component={TablePage} />
<Route exact path="/badges" component={BadgePage} />
<Route
exact
path="/button-groups"
component={ButtonGroupPage}
/>
<Route exact path="/button-groups" component={ButtonGroupPage} />
<Route exact path="/dropdowns" component={DropdownPage} />
<Route exact path="/progress" component={ProgressPage} />
<Route exact path="/modals" component={ModalPage} />
<Route exact path="/forms" component={FormPage} />
<Route exact path="/request" component={RequestPage} />
<Route exact path="/suggest" component={SuggestPage} />
<Route exact path="/input-groups" component={InputGroupPage} />
<Route exact path="/charts" component={ChartPage} />
<Route exact path="/course-class" component={CourseSearchPage}/>
<Route exact path="/stu-search" component={StuSearchPage}/>
<Route exact path="/ins-search" component={InsSearchPage}/>
<Route exact path="/news-board" component={NewsBoardPage}/>
<Route exact path="/faqs" component={FAQsPage}/>
<Route exact path="/aca-calender" component={AcaCalenderPage}/>
<Route exact path="/gpa" component={GPAPage}/>
<Route exact path="/profiles" component={ProfilePage}/>
</React.Suspense>
</MainLayout>
<Redirect to="/" />
Expand Down
Binary file added src/assets/img/Happy.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
37 changes: 1 addition & 36 deletions src/components/Layout/Header.js
Original file line number Diff line number Diff line change
Expand Up @@ -90,33 +90,7 @@ class Header extends React.Component {
</Nav>

<Nav navbar className={bem.e('nav-right')}>
<NavItem className="d-inline-flex">
<NavLink id="Popover1" className="position-relative">
{isNotificationConfirmed ? (
<MdNotificationsNone
size={25}
className="text-secondary can-click"
onClick={this.toggleNotificationPopover}
/>
) : (
<MdNotificationsActiveWithBadge
size={25}
className="text-secondary can-click animated swing infinite"
onClick={this.toggleNotificationPopover}
/>
)}
</NavLink>
<Popover
placement="bottom"
isOpen={this.state.isOpenNotificationPopover}
toggle={this.toggleNotificationPopover}
target="Popover1"
>
<PopoverBody>
<Notifications notificationsData={notificationsData} />
</PopoverBody>
</Popover>
</NavItem>


<NavItem>
<NavLink id="Popover2">
Expand All @@ -141,15 +115,6 @@ class Header extends React.Component {
className="border-light"
>
<ListGroup flush>
<ListGroupItem tag="button" action className="border-light">
<MdPersonPin /> Profile
</ListGroupItem>
<ListGroupItem tag="button" action className="border-light">
<MdInsertChart /> Stats
</ListGroupItem>
<ListGroupItem tag="button" action className="border-light">
<MdMessage /> Messages
</ListGroupItem>
<ListGroupItem tag="button" action className="border-light">
<MdSettingsApplications /> Settings
</ListGroupItem>
Expand Down
164 changes: 164 additions & 0 deletions src/components/Layout/Header_old.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,164 @@
import Avatar from 'components/Avatar';
import { UserCard } from 'components/Card';
import Notifications from 'components/Notifications';
import SearchInput from 'components/SearchInput';
import { notificationsData } from 'demos/header';
import withBadge from 'hocs/withBadge';
import React from 'react';
import {
MdClearAll,
MdExitToApp,
MdHelp,
MdInsertChart,
MdMessage,
MdNotificationsActive,
MdNotificationsNone,
MdPersonPin,
MdSettingsApplications,
} from 'react-icons/md';
import {
Button,
ListGroup,
ListGroupItem,
// NavbarToggler,
Nav,
Navbar,
NavItem,
NavLink,
Popover,
PopoverBody,
} from 'reactstrap';
import bn from 'utils/bemnames';

const bem = bn.create('header');

const MdNotificationsActiveWithBadge = withBadge({
size: 'md',
color: 'primary',
style: {
top: -10,
right: -10,
display: 'inline-flex',
justifyContent: 'center',
alignItems: 'center',
},
children: <small>5</small>,
})(MdNotificationsActive);

class Header extends React.Component {
state = {
isOpenNotificationPopover: false,
isNotificationConfirmed: false,
isOpenUserCardPopover: false,
};

toggleNotificationPopover = () => {
this.setState({
isOpenNotificationPopover: !this.state.isOpenNotificationPopover,
});

if (!this.state.isNotificationConfirmed) {
this.setState({ isNotificationConfirmed: true });
}
};

toggleUserCardPopover = () => {
this.setState({
isOpenUserCardPopover: !this.state.isOpenUserCardPopover,
});
};

handleSidebarControlButton = event => {
event.preventDefault();
event.stopPropagation();

document.querySelector('.cr-sidebar').classList.toggle('cr-sidebar--open');
};

render() {
const { isNotificationConfirmed } = this.state;

return (
<Navbar light expand className={bem.b('bg-white')}>
<Nav navbar className="mr-2">
<Button outline onClick={this.handleSidebarControlButton}>
<MdClearAll size={25} />
</Button>
</Nav>
<Nav navbar>
<SearchInput />
</Nav>

<Nav navbar className={bem.e('nav-right')}>
<NavItem className="d-inline-flex">
<NavLink id="Popover1" className="position-relative">
{isNotificationConfirmed ? (
<MdNotificationsNone
size={25}
className="text-secondary can-click"
onClick={this.toggleNotificationPopover}
/>
) : (
<MdNotificationsActiveWithBadge
size={25}
className="text-secondary can-click animated swing infinite"
onClick={this.toggleNotificationPopover}
/>
)}
</NavLink>
<Popover
placement="bottom"
isOpen={this.state.isOpenNotificationPopover}
toggle={this.toggleNotificationPopover}
target="Popover1"
>
<PopoverBody>
<Notifications notificationsData={notificationsData} />
</PopoverBody>
</Popover>
</NavItem>

<NavItem>
<NavLink id="Popover2">
<Avatar
onClick={this.toggleUserCardPopover}
className="can-click"
/>
</NavLink>
<Popover
placement="bottom-end"
isOpen={this.state.isOpenUserCardPopover}
toggle={this.toggleUserCardPopover}
target="Popover2"
className="p-0 border-0"
style={{ minWidth: 250 }}
>
<PopoverBody className="p-0 border-light">
<UserCard
title="Jane"
subtitle="[email protected]"
text="Last updated 3 mins ago"
className="border-light"
>
<ListGroup flush>
<ListGroupItem tag="button" action className="border-light">
<MdSettingsApplications /> Settings
</ListGroupItem>
<ListGroupItem tag="button" action className="border-light">
<MdHelp /> Help
</ListGroupItem>
<ListGroupItem tag="button" action className="border-light">
<MdExitToApp /> Signout
</ListGroupItem>
</ListGroup>
</UserCard>
</PopoverBody>
</Popover>
</NavItem>
</Nav>
</Navbar>
);
}
}

export default Header;
Loading