소스 검색

Merge pull request #5149 from overleaf/jel-gallery-official-badge

Add gallery official badge

GitOrigin-RevId: 6ac05bd9cabb211ff5bbb7a44b0c1940572b44e7
Jessica Lawshe 5 년 전
부모
커밋
690b123dd4
3개의 변경된 파일과 39개의 추가작업 그리고 3개의 파일을 삭제
  1. 2 1
      services/web/frontend/extracted-translations.json
  2. 34 1
      services/web/frontend/stylesheets/app/templates-v2.less
  3. 3 1
      services/web/locales/en.json

+ 2 - 1
services/web/frontend/extracted-translations.json

@@ -14,7 +14,6 @@
   "autocomplete": "",
   "autocomplete_references": "",
   "back_to_your_projects": "",
-  "beta_badge_tooltip": "",
   "blocked_filename": "",
   "can_edit": "",
   "cancel": "",
@@ -216,6 +215,7 @@
   "no_symbols_found": "",
   "normal": "",
   "off": "",
+  "official": "",
   "ok": "",
   "on": "",
   "optional": "",
@@ -305,6 +305,7 @@
   "sync_project_to_github_explanation": "",
   "sync_to_dropbox": "",
   "sync_to_github": "",
+  "template_approved_by_publisher": "",
   "terminated": "",
   "this_project_is_public": "",
   "this_project_is_public_read_only": "",

+ 34 - 1
services/web/frontend/stylesheets/app/templates-v2.less

@@ -1,5 +1,19 @@
-.gallery-title {
+.gallery-item-title {
+  * {
+    vertical-align: middle;
+  }
+  margin-top: @line-height-computed; // match h1 header margin-top
   margin-bottom: @margin-xl;
+  h1 {
+    display: inline;
+    margin: 0;
+  }
+}
+.gallery-official {
+  margin-left: @margin-sm;
+  &:extend(.label);
+  &:extend(.label-info);
+  cursor: default;
 }
 
 .field-title {
@@ -79,12 +93,31 @@
     .text-overflow();
   }
 
+  .gallery-list-item-title {
+    display: flex;
+    align-items: center;
+    justify-content: center;
+    * {
+      flex-basis: content;
+      cursor: inherit;
+    }
+  }
+
   .caption__title {
     display: inline-block;
     width: 100%;
     text-align: center;
     .text-overflow();
   }
+
+  a {
+    &:hover {
+      text-decoration: none; // disable underlining label
+      .caption__title {
+        text-decoration: underline;
+      }
+    }
+  }
 }
 
 .gallery-large-pdf-preview {

+ 3 - 1
services/web/locales/en.json

@@ -1495,5 +1495,7 @@
   "skip_to_content": "Skip to content",
   "logging_out": "Logging out",
   "share_thoughts_on_gallery": "Share your thoughts on the Overleaf Template Gallery!",
-  "take_short_survey": "Take a short survey"
+  "take_short_survey": "Take a short survey",
+  "official": "Official",
+  "template_approved_by_publisher": "This template has been approved by the publisher"
 }