aboutsummaryrefslogtreecommitdiff
path: root/src/client/util/GroupManager.tsx
diff options
context:
space:
mode:
authorusodhi <61431818+usodhi@users.noreply.github.com>2020-06-19 11:37:39 +0530
committerusodhi <61431818+usodhi@users.noreply.github.com>2020-06-19 11:37:39 +0530
commita4959a79b002a25617a84e6edff1148fff666c68 (patch)
tree2e44ad04c69d83c2c619faad17cd308702bdc749 /src/client/util/GroupManager.tsx
parent1a03c645e5801fe0cfe71e1b1744313a41523de6 (diff)
initial commit: added group document type + started setting up GroupManager
Diffstat (limited to 'src/client/util/GroupManager.tsx')
-rw-r--r--src/client/util/GroupManager.tsx43
1 files changed, 43 insertions, 0 deletions
diff --git a/src/client/util/GroupManager.tsx b/src/client/util/GroupManager.tsx
new file mode 100644
index 000000000..d9a20e1a7
--- /dev/null
+++ b/src/client/util/GroupManager.tsx
@@ -0,0 +1,43 @@
+import React from "react";
+import { observable, action } from "mobx";
+import { SelectionManager } from "./SelectionManager";
+import MainViewModal from "../views/MainViewModal";
+
+
+export default class GroupManager extends React.Component<{}>{
+
+ static Instance: GroupManager;
+ @observable private isOpen: boolean = false; // whether the menu is open or not
+ @observable private dialogueBoxOpacity = 1;
+ @observable private overlayOpacity = 0.4;
+
+ constructor(props: Readonly<{}>) {
+ super(props);
+ GroupManager.Instance = this;
+ }
+
+
+ open = action(() => {
+ SelectionManager.DeselectAll();
+ this.isOpen = true;
+ });
+
+ close = action(() => {
+ this.isOpen = false;
+ });
+
+ private get groupInterface() {
+ return <div>TESTING</div>;
+ }
+
+ render() {
+ return <MainViewModal
+ contents={this.groupInterface}
+ isDisplayed={this.isOpen}
+ interactive={true}
+ dialogueBoxDisplayedOpacity={this.dialogueBoxOpacity}
+ overlayDisplayedOpacity={this.overlayOpacity}
+ />;
+ }
+
+} \ No newline at end of file