summaryrefslogtreecommitdiff
path: root/pages/shop/_product
diff options
context:
space:
mode:
Diffstat (limited to 'pages/shop/_product')
-rw-r--r--pages/shop/_product/index.fnl21
1 files changed, 11 insertions, 10 deletions
diff --git a/pages/shop/_product/index.fnl b/pages/shop/_product/index.fnl
index c10a7d8..c3c2968 100644
--- a/pages/shop/_product/index.fnl
+++ b/pages/shop/_product/index.fnl
@@ -49,19 +49,16 @@
[:div {:class "content"}
[:div {:class "mb-1"} [:a {:href "/shop"} "⟵ Обратно к списку"]]
- (let [link (.. "/static/files/" product.image1)]
- (HTML [:a {:href link :target "_blank"}
- [:img {:class "product-page-img-mobile mb-1-5"
- :src (.. link "-thumbnail.jpg")}]]))
[:div {:class "product-page-layout"}
[:div {}
- [:h2 {:class "product-page-title mb-1"} product.title]
- [:section {:class "mb-2"}
+ [:h2 {:class "product-page-title"}
+ product.title
(if authenticated?
- (HTML [:div {:class "mb-0-5"}
- [:a {:href (.. "/shop/" product.name "/edit")}
- "✎ Редактировать"]])
- "")
+ (HTML [:a {:style "font-size: 1rem; margin-left: 0.75rem;"
+ :href (.. "/shop/" product.name "/edit")}
+ "% Редактировать"])
+ "")]
+ [:section {:class "mb-2"}
[:div {:class "mb-0-5" :style "font-style: italic;"}
(or (dicts.label dicts.tea-type product.type) product.type) ", "
(if (= product.packaging "piece")
@@ -69,6 +66,10 @@
(HTML [:span {}
[:strong {} (* 50 product.price-per) "₽ за 50 грамм "]
"(" product.price-per "₽ за 1 грамм)"]))]]
+ (let [link (.. "/static/files/" product.image1)]
+ (HTML [:a {:href link :target "_blank"}
+ [:img {:class "product-page-img-mobile mb-2"
+ :src (.. link "-thumbnail.jpg")}]]))
[:div {:class "mb-2"} "~~~"]
[:NO-ESCAPE (text->html product.description)]]
[:div {:class "product-page-imgs"}