You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Make widget modal positioning responsive for mobile devices
- Reduce data-modal-y-offset from 18vh to 12vh for better mobile experience
- Add responsive CSS media queries for different screen sizes
- Mobile (≤768px): 60px margin-top, 85vh max-height
- Small mobile (≤480px): 40px margin-top, 90vh max-height
Copy file name to clipboardExpand all lines: src/current/_includes/head.html
+16-1Lines changed: 16 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -151,7 +151,7 @@
151
151
data-kapa-branding-hide="true"
152
152
data-modal-title="CockroachDB AI"
153
153
data-modal-disclaimer="This AI bot is experimental. Don't rely on it for production workloads. Always consult the official CockroachDB documentation. Interactions with this AI bot may be monitored or recorded, and your use of the AI bot is subject to the Cockroach Labs' [Terms of Use](https://www.cockroachlabs.com/website-terms-of-use/) and [Privacy policy](https://www.cockroachlabs.com/privacy/)."
154
-
data-modal-y-offset="18vh"
154
+
data-modal-y-offset="12vh"
155
155
data-modal-z-index="1000"
156
156
></script>
157
157
@@ -162,4 +162,19 @@
162
162
.mantine-Modal-content {
163
163
max-height:calc(75vh); /* Limits the modal's height to 75% of the viewport height */
164
164
}
165
+
166
+
/* Responsive modal positioning for Kapa widget */
167
+
@media (max-width:768px) {
168
+
.mantine-Modal-content {
169
+
margin-top:60px!important; /* Reduced margin for mobile */
170
+
max-height:calc(85vh); /* More height available on mobile */
171
+
}
172
+
}
173
+
174
+
@media (max-width:480px) {
175
+
.mantine-Modal-content {
176
+
margin-top:40px!important; /* Even smaller margin for small mobile screens */
177
+
max-height:calc(90vh); /* Maximum height utilization on small screens */
0 commit comments