Просмотр исходного кода

Merge pull request #12249 from overleaf/tm-gallery-top-picks

Implement top picks in template gallery for CVs

GitOrigin-RevId: 22f720582e27fac2b9e454ce4e28bd124de094b7
Jessica Lawshe 3 лет назад
Родитель
Сommit
6fc5385ca6

+ 25 - 0
services/web/frontend/stylesheets/app/templates-v2.less

@@ -128,6 +128,31 @@
   }
 }
 
+@top-picks-banner-extra-width: 50px;
+.top-picks-banner {
+  padding: 0px;
+  width: 100%;
+  margin-left: auto;
+  margin-right: auto;
+
+  @media (min-width: (@screen-lg-min + @top-picks-banner-extra-width)) {
+    width: @container-lg + @top-picks-banner-extra-width;
+  }
+
+  @media (max-width: (@screen-lg-min + @top-picks-banner-extra-width - 1)) {
+    border-radius: 0;
+  }
+}
+
+.gallery-top-pick-badge {
+  margin-left: @margin-sm;
+  &:extend(.label);
+  &:extend(.label-primary);
+  cursor: default;
+  font-size: 14px;
+  padding: 3px 8px;
+}
+
 /* Media Queries */
 @media (max-width: @screen-xs-max) {
   .gallery-container {

+ 6 - 0
services/web/frontend/stylesheets/components/card.less

@@ -81,3 +81,9 @@
   background-color: @card-gray-bg-color;
   border-radius: @card-border-radius;
 }
+
+.card-gray-dark {
+  &:extend(.card);
+  background-color: @ol-blue-gray-1;
+  border-radius: @card-border-radius;
+}

+ 2 - 0
services/web/locales/en.json

@@ -1481,6 +1481,7 @@
   "template_gallery": "Template Gallery",
   "template_not_found_description": "This way of creating projects from templates has been removed. Please visit our template gallery to find more templates.",
   "template_title_taken_from_project_title": "The template title will be taken automatically from the project title",
+  "template_top_pick_by_overleaf": "This template was hand-picked by Overleaf staff for its high quality",
   "templates": "Templates",
   "terminated": "Compilation cancelled",
   "terms": "Terms",
@@ -1559,6 +1560,7 @@
   "tooltip_hide_pdf": "Click to hide the PDF",
   "tooltip_show_filetree": "Click to show the file-tree",
   "tooltip_show_pdf": "Click to show the PDF",
+  "top_pick": "Top pick",
   "total_per_month": "Total per month",
   "total_per_year": "Total per year",
   "total_per_year_for_x_users": "total per year for __licenseSize__ users",