From f34907af6ec100f5674c02b97476b4015ae8606a Mon Sep 17 00:00:00 2001
From: Azza Ahmed <a.e.ahmed@tudelft.nl>
Date: Thu, 8 May 2025 10:50:55 +0200
Subject: [PATCH] add Gurubase widget integration and enable custom head
 configuration

---
 config.toml                       |  2 ++
 layouts/partials/custom-head.html | 17 +++++++++++++++++
 2 files changed, 19 insertions(+)
 create mode 100644 layouts/partials/custom-head.html

diff --git a/config.toml b/config.toml
index 4a0dfe8..0904870 100644
--- a/config.toml
+++ b/config.toml
@@ -119,6 +119,8 @@ priority = 0.5
 
 # User interface configuration
 [params.ui]
+# To enable gurubase
+custom_head = ["custom-head.html"]
 #  Set to true to disable breadcrumb navigation.
 breadcrumb_disable = false
 # Set to true to disable the About link in the site footer
diff --git a/layouts/partials/custom-head.html b/layouts/partials/custom-head.html
new file mode 100644
index 0000000..8043ee8
--- /dev/null
+++ b/layouts/partials/custom-head.html
@@ -0,0 +1,17 @@
+<!-- Gurubase Widget -->
+Live Widget
+<script async src="https://widget.gurubase.io/widget.latest.min.js" 
+    data-widget-id="daHYtXHdDXuG9kL3bddrWFB7ZLmUXNyfdgC_fSDIajo"
+    data-text="Ask AI"
+    data-margins='{"bottom": "1rem", "right": "1rem"}'
+    data-light-mode="auto"
+    id="guru-widget-id">
+</script>
+<!-- Local Widget -->
+<!-- <script async src="https://widget.gurubase.io/widget.latest.min.js" 
+    data-widget-id="_qyuCVp0sqLqgTWY_bDjmcsHHFtlMB2PfwV9UwqrZQQ"
+    data-text="Ask AI"
+    data-margins='{"bottom": "1rem", "right": "1rem"}'
+    data-light-mode="auto"
+    id="guru-widget-id">
+</script> -->
-- 
GitLab