[Libreoffice-commits] help.git: help3xsl/default.css help3xsl/online_transform.xsl

Olivier Hallot (via logerrit) logerrit at kemper.freedesktop.org
Fri Oct 11 11:02:09 UTC 2019


 help3xsl/default.css          |   70 +++++++++++++++++++-----------------------
 help3xsl/online_transform.xsl |   10 +++---
 2 files changed, 38 insertions(+), 42 deletions(-)

New commits:
commit 2e077c0f9f724a3fe258c8e92aa3f67b7ab75446
Author:     Olivier Hallot <olivier.hallot at libreoffice.org>
AuthorDate: Thu Oct 10 09:20:18 2019 -0300
Commit:     Olivier Hallot <olivier.hallot at libreoffice.org>
CommitDate: Fri Oct 11 13:01:44 2019 +0200

    Fix xapian search bar in Help online (WIP)
    
    Change-Id: Ibe178ff79a27b8a21fcbaf2465c66da0786a28fd
    WIP: need adjusts for mobile.
    Reviewed-on: https://gerrit.libreoffice.org/80605
    Tested-by: Jenkins
    Reviewed-by: Olivier Hallot <olivier.hallot at libreoffice.org>

diff --git a/help3xsl/default.css b/help3xsl/default.css
index f71cb6885..a68fc0067 100644
--- a/help3xsl/default.css
+++ b/help3xsl/default.css
@@ -347,11 +347,11 @@ h6 {
     grid-area: header;
     position: sticky;
     top: 0px;
-    background-color: #18A303;
     z-index: 1000;
 }
 header {
     color: #fff;
+    background-color: #18A303;
     height: 64px;
     padding: 8px 8px 8px 16px;
 }
@@ -461,6 +461,10 @@ aside input[type=checkbox]:checked ~ .contents-treeview {
 }
 .index a {
     font-size: 16px;
+    display: block;
+}
+.index .hidden {
+    display: none;
 }
 #Bookmarks {
     padding: 0 20px;
@@ -544,12 +548,6 @@ aside input[type=checkbox]:checked ~ .contents-treeview {
 .pagination a {
     text-decoration: none;
 }
-.index a {
-    display: block;
-}
-.index .hidden {
-    display: none;
-}
 li.active {
     background-color: #0379BC;
 }
@@ -582,12 +580,15 @@ li.disabled a {
     background-color: #FCFCFC;
     box-shadow: 0 2px 8px 0 rgba(0,0,0,.05);
 }
-.donation {
+.donation-frame {
+    background: #18A303;
+}
+.donation{
     background: #0379BC;
     background-image: linear-gradient(to bottom, #3498db, #2980b9);
     border-radius: 8px;
     padding: 5px 10px 5px 10px;
-    margin: 20px auto 0 auto;
+    margin: auto;
     max-width: 200px;
     color: #ffffff;
     text-decoration: none;
@@ -607,15 +608,11 @@ li.disabled a {
     font-size:1.2rem;
     text-align: center;
 }
-/*.xapian-omega-search {
-    max-width: 300px;
-    margin: 40px auto 0 auto;
-}*/
+.search-frame {
+    background: #18A303;
+}
 .xapian-omega-search {
-    margin: 0;
-    /*position: absolute;*/
-    top: 19px;
-    left: 360px;
+    margin: auto;
 }
 .modules {
     border-bottom: 2px solid #f3f3f3;
@@ -809,16 +806,11 @@ li.disabled a {
     .rightside {
         grid-area: rightside;
     }
-    .xapian-donation {
-        grid-area: google;
-        position: sticky;
-        top: 0px;
-        background-color: #FCFCFC;
-        box-shadow: none;
-        clear: left;
+    .donation-frame {
+        grid-area: donation;
     }
-    .donation {
-        max-width: 400px;
+    .search-frame {
+        grid-area: search;
     }
     footer {
         grid-area: footer;
@@ -863,27 +855,26 @@ li.disabled a {
 /* Use @supports to sneak these rules past IE */
 @supports (grid-area: auto) {
     @media screen and (min-width: 960px) {
-        .xapian-donation {
+        .search-frame {
+            grid-area: search;
             display: flex;
             justify-content: space-between;
             align-items: center;
-            background-color: #18A303;
-            border-top: none;
-        }
-        .xapian-omega-search {
-            margin: 0;
         }
-        .donation {
-            margin: 0 auto;
+        .donation-frame {
+            grid-area: donation;
+            display: flex;
+            justify-content: space-between;
+            align-items: center;
         }
         footer {
             border-top: 2px solid #148603;
         }
         body {
             display: grid;
-            grid-template-columns: 320px 80px 1fr;
+            grid-template-columns: 360px 80px 1fr;
             grid-template-rows: minmax(1em, auto) minmax(1em, auto) 1fr minmax(1em, auto);
-            grid-template-areas: "header header google"
+            grid-template-areas: "header search donation"
                                  "rightside main main"
                                  "leftside main main"
                                  ". footer footer"
@@ -892,12 +883,15 @@ li.disabled a {
     @media screen and (min-width: 1440px) {
         body {
             display: grid;
-            grid-template-columns: 320px 450px 450px 1fr;
+            grid-template-columns: 360px 450px 450px 1fr;
             grid-template-rows: 1fr minmax(1em, auto) minmax(1em, auto);
-            grid-template-areas: "header header google google"
+            grid-template-areas: "header search search donation"
                                  "leftside main main rightside"
                                  ". footer footer ."
         }
+        .donation {
+            max-width: 300px;
+        }
         .rightside {
             width: auto;
             border-right: none;
diff --git a/help3xsl/online_transform.xsl b/help3xsl/online_transform.xsl
index f8d6dc2f9..ec56991f6 100644
--- a/help3xsl/online_transform.xsl
+++ b/help3xsl/online_transform.xsl
@@ -222,19 +222,21 @@
         <xsl:apply-templates select="/helpdocument/body"/>
     </div>
     <xsl:if test="$online">
-        <div class="xapian-donation">
             <xsl:if test="$xapian='yes'">
+                <div class="search-frame">
                 <div class="xapian-omega-search">
                     <form name="P" method="get" action="/{$productversion}/{$lang}/search" target="_top">
-                        <input id="omega-autofocus" type="search" name="P" size="65"/>
+                        <input id="omega-autofocus" type="search" name="P" size="40"/>
                         <input type="submit" class="xapian-omega-search-button" value="&#x1f50d;"/>
                     </form>
                 </div>
+            </div>
             </xsl:if>
-            <div class="donation">
+            <div class="donation-frame">
+                <div class="donation">
                 <p><a href="https://www.libreoffice.org/donate/?pk_campaign=help" target ="_blank"><xsl:value-of select="$ui_donate"/></a></p>
+                </div>
             </div>
-        </div>
     </xsl:if>
     <footer>
         <xsl:if test="$online">


More information about the Libreoffice-commits mailing list