diff --git a/config/integrations/googledocs_widget.yaml b/config/integrations/googledocs_widget.yaml
new file mode 100644
index 0000000..170f15f
--- /dev/null
+++ b/config/integrations/googledocs_widget.yaml
@@ -0,0 +1,7 @@
+# All this configuration does is make "Google Docs Widget" available in the UI
+type: "widget"
+integrationType: "googledocs"
+enabled: true
+name: "Google Docs"
+about: "Collaborate on and share documents using Google Docs"
+avatar: "img/avatars/googledocs.png"
\ No newline at end of file
diff --git a/web/app/configs/widget/googledocs/googledocs-config.component.html b/web/app/configs/widget/googledocs/googledocs-config.component.html
new file mode 100644
index 0000000..1223b92
--- /dev/null
+++ b/web/app/configs/widget/googledocs/googledocs-config.component.html
@@ -0,0 +1,59 @@
+
+
+
+
+
+
diff --git a/web/app/configs/widget/googledocs/googledocs-config.component.scss b/web/app/configs/widget/googledocs/googledocs-config.component.scss
new file mode 100644
index 0000000..92dce18
--- /dev/null
+++ b/web/app/configs/widget/googledocs/googledocs-config.component.scss
@@ -0,0 +1,4 @@
+// component styles are encapsulated and only applied to their components
+.widget-item {
+ margin-top: 3px;
+}
diff --git a/web/app/configs/widget/googledocs/googledocs-config.component.ts b/web/app/configs/widget/googledocs/googledocs-config.component.ts
new file mode 100644
index 0000000..f952da3
--- /dev/null
+++ b/web/app/configs/widget/googledocs/googledocs-config.component.ts
@@ -0,0 +1,44 @@
+import { Component } from "@angular/core";
+import { DialogRef, ModalComponent } from "ngx-modialog";
+import { WidgetComponent } from "../widget.component";
+import { ScalarService } from "../../../shared/scalar.service";
+import { ConfigModalContext } from "../../../integration/integration.component";
+import { ToasterService } from "angular2-toaster";
+import { Widget, WIDGET_DIM_GOOGLEDOCS, WIDGET_SCALAR_GOOGLEDOCS } from "../../../shared/models/widget";
+
+@Component({
+ selector: "my-googledocswidget-config",
+ templateUrl: "googledocs-config.component.html",
+ styleUrls: ["googledocs-config.component.scss", "./../../config.component.scss"],
+})
+export class GoogleDocsWidgetConfigComponent extends WidgetComponent implements ModalComponent {
+
+ constructor(public dialog: DialogRef,
+ toaster: ToasterService,
+ scalarService: ScalarService,
+ window: Window) {
+ super(
+ toaster,
+ scalarService,
+ dialog.context.roomId,
+ window,
+ WIDGET_DIM_GOOGLEDOCS,
+ WIDGET_SCALAR_GOOGLEDOCS,
+ dialog.context.integration,
+ dialog.context.integrationId,
+ "Google Docs",
+ "generic", // wrapper
+ "googleDocs" // scalar wrapper
+ );
+ }
+
+ public validateAndAddWidget() {
+ // We don't actually validate anything here, but we could
+ this.addWidget({dimOriginalUrl: this.newWidgetUrl});
+ }
+
+ public validateAndSaveWidget(widget: Widget) {
+ // We don't actually validate anything here, but we could
+ this.saveWidget(widget);
+ }
+}
diff --git a/web/app/shared/integration.service.ts b/web/app/shared/integration.service.ts
index 62a4bbd..ad12b1b 100644
--- a/web/app/shared/integration.service.ts
+++ b/web/app/shared/integration.service.ts
@@ -11,11 +11,12 @@ import { EtherpadWidgetConfigComponent } from "../configs/widget/etherpad/etherp
import { JitsiWidgetConfigComponent } from "../configs/widget/jitsi/jitsi-config.component";
import {
WIDGET_DIM_CUSTOM,
- WIDGET_DIM_ETHERPAD,
+ WIDGET_DIM_ETHERPAD, WIDGET_DIM_GOOGLEDOCS,
WIDGET_DIM_JITSI,
WIDGET_DIM_TWITCH,
WIDGET_DIM_YOUTUBE
} from "./models/widget";
+import { GoogleDocsWidgetConfigComponent } from "../configs/widget/googledocs/googledocs-config.component";
@Injectable()
export class IntegrationService {
@@ -56,6 +57,10 @@ export class IntegrationService {
component: JitsiWidgetConfigComponent,
screenId: "type_" + WIDGET_DIM_JITSI,
},
+ "googledocs": {
+ component: GoogleDocsWidgetConfigComponent,
+ screenId: "type_" + WIDGET_DIM_GOOGLEDOCS,
+ },
},
};
diff --git a/web/app/shared/models/widget.ts b/web/app/shared/models/widget.ts
index 5c160a3..f3b1fc1 100644
--- a/web/app/shared/models/widget.ts
+++ b/web/app/shared/models/widget.ts
@@ -16,6 +16,7 @@ export const WIDGET_DIM_YOUTUBE = "dimension-youtube";
export const WIDGET_DIM_TWITCH = "dimension-twitch";
export const WIDGET_DIM_ETHERPAD = "dimension-etherpad";
export const WIDGET_DIM_JITSI = "dimension-jitsi";
+export const WIDGET_DIM_GOOGLEDOCS = "dimension-googledocs";
export interface Widget {
id: string;