aboutsummaryrefslogtreecommitdiff
path: root/lib/classes/sidebar/VueWidget.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/classes/sidebar/VueWidget.php')
-rw-r--r--lib/classes/sidebar/VueWidget.php20
1 files changed, 20 insertions, 0 deletions
diff --git a/lib/classes/sidebar/VueWidget.php b/lib/classes/sidebar/VueWidget.php
new file mode 100644
index 0000000..f4f0583
--- /dev/null
+++ b/lib/classes/sidebar/VueWidget.php
@@ -0,0 +1,20 @@
+<?php
+/**
+ * This widget type delegates all rendering of the widget to vuejs.
+ *
+ * @author Elmar Ludwig
+ * @license GPL2 or any later version
+ * @since Stud.IP 5.0
+ */
+class VueWidget extends Widget
+{
+ /**
+ * Constructs the widget with the given id on the element.
+ */
+ public function __construct($id)
+ {
+ $this->id = $id;
+ $this->layout = 'widgets/vue-widget';
+ $this->forced_rendering = true;
+ }
+}