Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-docs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAchilleas Pipinellis <axil@gitlab.com>2017-12-15 15:35:04 +0300
committerAchilleas Pipinellis <axil@gitlab.com>2017-12-15 15:35:04 +0300
commit276f85becc933b5c6a161f7f68ca27a65a240397 (patch)
tree7e4436039d7a99ff3cfcf01607ec5957ac4085e8 /content
parentc5f74ae742486c21a2a448615eba5280fbeb146f (diff)
parent5c9f6e025e080a836c9c7f47239f40c4e797f786 (diff)
Merge branch 'algolia-mobile' into 'master'
Make Algolia search mobile friendly Closes #72 See merge request gitlab-com/gitlab-docs!170
Diffstat (limited to 'content')
-rw-r--r--content/assets/stylesheets/stylesheet.scss30
1 files changed, 30 insertions, 0 deletions
diff --git a/content/assets/stylesheets/stylesheet.scss b/content/assets/stylesheets/stylesheet.scss
index f39c8bc5..05f51c03 100644
--- a/content/assets/stylesheets/stylesheet.scss
+++ b/content/assets/stylesheets/stylesheet.scss
@@ -555,3 +555,33 @@ h6 {
.alert {
color: inherit;
}
+
+//
+// Algolia search for mobile
+// https://github.com/algolia/docsearch/issues/181#issuecomment-301730219
+//
+// Since some values are added by Javascript, we have to add the
+// !important option to override these values.
+// scss-lint:disable ImportantRule
+.algolia-autocomplete {
+ // On a max-width of 768px
+ @media (max-width: 768px) {
+ .ds-dropdown-menu {
+ max-width: calc(100vw - 32px) !important;
+ min-width: calc(100vw - 32px) !important;
+ width: calc(100vw - 32px) !important;
+ margin-left: 16px !important;
+ }
+ .algolia-docsearch-suggestion--content {
+ width: 100% !important;
+ padding-left: 0 !important;
+ }
+ .algolia-docsearch-suggestion--content::before {
+ display: none !important;
+ }
+ .algolia-docsearch-suggestion--subcategory-column {
+ display: none !important;
+ }
+ }
+}
+// scss-lint:enable ImportantRule