hour mode, day of week, view date
This commit is contained in:
1 parent
15427084d7
commit
5e9f6945c3
11 files changed
+145
-26
No files matched your search
+1
-1
@@ -9,7 +9,7 @@ const App = () => {
|
||||
const [view, setView] = React.useState<ViewMode>(ViewMode.Day);
|
||||
const [tasks, setTasks] = React.useState<Task[]>(initTasks());
|
||||
const [isChecked, setIsChecked] = React.useState(true);
|
||||
let columnWidth = 60;
|
||||
let columnWidth = 65;
|
||||
if (view === ViewMode.Month) {
|
||||
columnWidth = 300;
|
||||
} else if (view === ViewMode.Week) {
|
||||
|
||||
@@ -13,6 +13,12 @@ export const ViewSwitcher: React.SFC<ViewSwitcherProps> = ({
|
||||
}) => {
|
||||
return (
|
||||
<div className="ViewContainer">
|
||||
<button
|
||||
className="Button"
|
||||
onClick={() => onViewModeChange(ViewMode.Hour)}
|
||||
>
|
||||
Hour
|
||||
</button>
|
||||
<button
|
||||
className="Button"
|
||||
onClick={() => onViewModeChange(ViewMode.QuarterDay)}
|
||||
|
||||
@@ -2,4 +2,4 @@
|
||||
// allows you to do things like:
|
||||
// expect(element).toHaveTextContent(/react/i)
|
||||
// learn more: https://github.com/testing-library/jest-dom
|
||||
import '@testing-library/jest-dom/extend-expect';
|
||||
import "@testing-library/jest-dom/extend-expect";
|
||||
Reference in new issue
Block a user