spree_frontend 4.2.3 → 4.3.0.rc1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (157) hide show
  1. checksums.yaml +4 -4
  2. data/Rakefile +1 -1
  3. data/app/assets/config/spree_frontend_manifest.js +4 -0
  4. data/app/assets/images/card-image.svg +4 -0
  5. data/app/assets/images/file-image.svg +4 -0
  6. data/app/assets/images/image.svg +4 -0
  7. data/app/assets/images/noimage/large.png +0 -0
  8. data/app/assets/images/noimage/mini.png +0 -0
  9. data/app/assets/images/noimage/plp.svg +23 -0
  10. data/app/assets/images/noimage/product.png +0 -0
  11. data/app/assets/images/noimage/small.png +0 -0
  12. data/app/assets/javascripts/spree.js +78 -0
  13. data/app/assets/javascripts/spree/api/main.js +36 -0
  14. data/app/assets/javascripts/spree/api/storefront/cart.js +49 -0
  15. data/app/assets/javascripts/spree/frontend.js +3 -0
  16. data/app/assets/javascripts/spree/frontend/checkout.js +16 -0
  17. data/app/assets/javascripts/spree/frontend/checkout/payment.js +18 -5
  18. data/app/assets/javascripts/spree/frontend/currency.js +11 -9
  19. data/app/assets/javascripts/spree/frontend/locale.es6 +13 -0
  20. data/app/assets/javascripts/spree/frontend/views/spree/home/product_carousels.js +3 -3
  21. data/app/assets/javascripts/spree/frontend/views/spree/products/index.js +0 -9
  22. data/app/assets/javascripts/spree/frontend/views/spree/products/price_filters.es6 +46 -0
  23. data/app/assets/stylesheets/spree/frontend/application.scss +1 -0
  24. data/app/assets/stylesheets/spree/frontend/components-bootstrap/button.scss +8 -0
  25. data/app/assets/stylesheets/spree/frontend/helpers/spree/frontend_helper.scss +41 -0
  26. data/app/assets/stylesheets/spree/frontend/variables/variables.scss +2 -2
  27. data/app/assets/stylesheets/spree/frontend/views/spree/checkout/edit.scss +17 -5
  28. data/app/assets/stylesheets/spree/frontend/views/spree/cms_sections/_index.scss +1 -0
  29. data/app/assets/stylesheets/spree/frontend/views/spree/cms_sections/product_buy_bar.scss +20 -0
  30. data/app/assets/stylesheets/spree/frontend/views/spree/home/index.scss +54 -67
  31. data/app/assets/stylesheets/spree/frontend/views/spree/shared/category_nav_bar.scss +3 -3
  32. data/app/assets/stylesheets/spree/frontend/views/spree/shared/footer.scss +4 -0
  33. data/app/assets/stylesheets/spree/frontend/views/spree/shared/main_nav_bar.scss +12 -1
  34. data/app/controllers/spree/addresses_controller.rb +14 -19
  35. data/app/controllers/spree/checkout_controller.rb +5 -3
  36. data/app/controllers/spree/cms_pages_controller.rb +29 -0
  37. data/app/controllers/spree/content_controller.rb +0 -2
  38. data/app/controllers/spree/errors_controller.rb +11 -0
  39. data/app/controllers/spree/home_controller.rb +34 -1
  40. data/app/controllers/spree/locale_controller.rb +7 -1
  41. data/app/controllers/spree/orders_controller.rb +9 -7
  42. data/app/controllers/spree/products_controller.rb +14 -13
  43. data/app/controllers/spree/store_controller.rb +25 -1
  44. data/app/controllers/spree/taxons_controller.rb +12 -5
  45. data/app/helpers/spree/addresses_helper.rb +9 -4
  46. data/app/helpers/spree/cms_pages_helper.rb +23 -0
  47. data/app/helpers/spree/frontend_helper.rb +109 -10
  48. data/app/helpers/spree/navigation_helper.rb +73 -4
  49. data/app/helpers/spree/products_filters_helper.rb +168 -0
  50. data/app/helpers/spree/store_helper.rb +3 -1
  51. data/app/views/spree/checkout/_address.html.erb +1 -1
  52. data/app/views/spree/checkout/_credit_card.html.erb +1 -0
  53. data/app/views/spree/cms_pages/show.html.erb +16 -0
  54. data/app/views/spree/errors/forbidden.html.erb +0 -0
  55. data/app/views/spree/errors/unauthorized.html.erb +0 -0
  56. data/app/views/spree/home/index.html.erb +19 -118
  57. data/app/views/spree/layouts/spree_application.html.erb +1 -1
  58. data/app/views/spree/products/_description.html.erb +16 -19
  59. data/app/views/spree/products/_filters_desktop.html.erb +50 -15
  60. data/app/views/spree/products/_filters_mobile.html.erb +38 -10
  61. data/app/views/spree/products/_sort_desktop.html.erb +17 -11
  62. data/app/views/spree/products/_sort_mobile.html.erb +16 -0
  63. data/app/views/spree/products/index.html.erb +1 -1
  64. data/app/views/spree/shared/_carousel_4_products.html.erb +2 -2
  65. data/app/views/spree/shared/_checkout_header.html.erb +22 -21
  66. data/app/views/spree/shared/_copyright.html.erb +1 -1
  67. data/app/views/spree/shared/_footer.html.erb +15 -9
  68. data/app/views/spree/shared/_head.html.erb +1 -1
  69. data/app/views/spree/shared/_header.html.erb +3 -3
  70. data/app/views/spree/shared/_main_nav_bar.html.erb +61 -43
  71. data/app/views/spree/shared/_mobile_navigation.html.erb +30 -19
  72. data/app/views/spree/shared/_nav_bar.html.erb +1 -1
  73. data/app/views/spree/shared/_option_values.html.erb +2 -21
  74. data/app/views/spree/shared/_order_details.html.erb +1 -1
  75. data/app/views/spree/shared/_paths.html.erb +8 -0
  76. data/app/views/spree/shared/_properties.html.erb +4 -0
  77. data/app/views/spree/shared/_translations.html.erb +2 -1
  78. data/app/views/spree/shared/carousel/_single.html.erb +1 -1
  79. data/app/views/spree/shared/carousel/_thumbnails.html.erb +1 -1
  80. data/app/views/spree/shared/cms/pages/_edit_mode.html.erb +13 -0
  81. data/app/views/spree/shared/cms/sections/_featured_article.html.erb +27 -0
  82. data/app/views/spree/shared/cms/sections/_hero_image.html.erb +60 -0
  83. data/app/views/spree/shared/cms/sections/_image_gallery.html.erb +171 -0
  84. data/app/views/spree/shared/cms/sections/_product_carousel.html.erb +5 -0
  85. data/app/views/spree/shared/cms/sections/_rich_text_content.html.erb +3 -0
  86. data/app/views/spree/shared/cms/sections/_side_by_side_images.html.erb +118 -0
  87. data/app/views/spree/taxons/_header.html.erb +6 -1
  88. data/app/views/spree/users/show.html.erb +1 -1
  89. data/config/initializers/assets.rb +4 -13
  90. data/config/routes.rb +9 -3
  91. data/lib/generators/spree/frontend/install/install_generator.rb +5 -5
  92. data/lib/generators/spree/frontend/install/templates/app/assets/config/manifest.js +2 -0
  93. data/lib/generators/spree/frontend/install/templates/vendor/assets/javascripts/spree/frontend/all.js +8 -0
  94. data/lib/generators/spree/frontend/install/templates/vendor/assets/stylesheets/spree/frontend/all.css +9 -0
  95. data/lib/spree/frontend.rb +6 -3
  96. data/lib/spree/frontend/engine.rb +6 -0
  97. data/spec/fixtures/files/store_favicon.ico +0 -0
  98. data/spree_frontend.gemspec +12 -8
  99. data/vendor/assets/javascripts/cleave.js +8 -0
  100. data/vendor/assets/javascripts/fetch.umd.js +531 -0
  101. data/vendor/assets/javascripts/jquery.payment.js +652 -0
  102. data/vendor/assets/javascripts/jsuri.js +458 -0
  103. data/vendor/assets/javascripts/polyfill.min.js +1 -0
  104. metadata +130 -84
  105. data/app/assets/images/homepage/big_category_banner.jpg +0 -0
  106. data/app/assets/images/homepage/big_category_banner_mobile.jpg +0 -0
  107. data/app/assets/images/homepage/big_category_banner_tablet_landscape.jpg +0 -0
  108. data/app/assets/images/homepage/big_category_banner_tablet_portrait.jpg +0 -0
  109. data/app/assets/images/homepage/category_banner_lower.jpg +0 -0
  110. data/app/assets/images/homepage/category_banner_lower_mobile.jpg +0 -0
  111. data/app/assets/images/homepage/category_banner_lower_tablet_landscape.jpg +0 -0
  112. data/app/assets/images/homepage/category_banner_lower_tablet_portrait.jpg +0 -0
  113. data/app/assets/images/homepage/category_banner_upper.jpg +0 -0
  114. data/app/assets/images/homepage/category_banner_upper_mobile.jpg +0 -0
  115. data/app/assets/images/homepage/category_banner_upper_tablet_landscape.jpg +0 -0
  116. data/app/assets/images/homepage/category_banner_upper_tablet_portrait.jpg +0 -0
  117. data/app/assets/images/homepage/main_banner.jpg +0 -0
  118. data/app/assets/images/homepage/main_banner_mobile.jpg +0 -0
  119. data/app/assets/images/homepage/main_banner_tablet_landscape.jpg +0 -0
  120. data/app/assets/images/homepage/main_banner_tablet_portrait.jpg +0 -0
  121. data/app/assets/images/homepage/promo_banner_left.jpg +0 -0
  122. data/app/assets/images/homepage/promo_banner_left_mobile.jpg +0 -0
  123. data/app/assets/images/homepage/promo_banner_left_tablet_landscape.jpg +0 -0
  124. data/app/assets/images/homepage/promo_banner_left_tablet_portrait.jpg +0 -0
  125. data/app/assets/images/homepage/promo_banner_right.jpg +0 -0
  126. data/app/assets/images/homepage/promo_banner_right_mobile.jpg +0 -0
  127. data/app/assets/images/homepage/promo_banner_right_tablet_landscape.jpg +0 -0
  128. data/app/assets/images/homepage/promo_banner_right_tablet_portrait.jpg +0 -0
  129. data/app/assets/images/meganav/promo_banner_left-first-category.jpg +0 -0
  130. data/app/assets/images/meganav/promo_banner_left-second-category.jpg +0 -0
  131. data/app/assets/images/meganav/promo_banner_left-third-category.jpg +0 -0
  132. data/app/assets/images/meganav/promo_banner_right-first-category.jpg +0 -0
  133. data/app/assets/images/meganav/promo_banner_right-second-category.jpg +0 -0
  134. data/app/assets/images/meganav/promo_banner_right-third-category.jpg +0 -0
  135. data/app/assets/images/noimage/big_category_banner.jpg +0 -0
  136. data/app/assets/images/noimage/big_category_banner_mobile.jpg +0 -0
  137. data/app/assets/images/noimage/big_category_banner_tablet_landscape.jpg +0 -0
  138. data/app/assets/images/noimage/big_category_banner_tablet_portrait.jpg +0 -0
  139. data/app/assets/images/noimage/category_banner.jpg +0 -0
  140. data/app/assets/images/noimage/category_banner_mobile.jpg +0 -0
  141. data/app/assets/images/noimage/category_banner_plp.jpg +0 -0
  142. data/app/assets/images/noimage/category_banner_tablet_landscape.jpg +0 -0
  143. data/app/assets/images/noimage/category_banner_tablet_portrait.jpg +0 -0
  144. data/app/assets/images/noimage/main_banner.jpg +0 -0
  145. data/app/assets/images/noimage/main_banner_mobile.jpg +0 -0
  146. data/app/assets/images/noimage/main_banner_tablet_landscape.jpg +0 -0
  147. data/app/assets/images/noimage/main_banner_tablet_portrait.jpg +0 -0
  148. data/app/assets/images/noimage/product_photo.jpg +0 -0
  149. data/app/assets/images/noimage/promo_banner.jpg +0 -0
  150. data/app/assets/images/noimage/promo_banner_megamenu.jpg +0 -0
  151. data/app/assets/images/noimage/promo_banner_mobile.jpg +0 -0
  152. data/app/assets/images/noimage/promo_banner_tablet_landscape.jpg +0 -0
  153. data/app/assets/images/noimage/promo_banner_tablet_portrait.jpg +0 -0
  154. data/app/assets/javascripts/spree/frontend/locale.js +0 -13
  155. data/app/assets/javascripts/spree/frontend/multi_currency.js +0 -13
  156. data/lib/generators/spree/frontend/install/templates/config/initializers/spree_storefront.rb +0 -1
  157. data/lib/generators/spree/frontend/install/templates/config/spree_storefront.yml +0 -99
@@ -1,13 +0,0 @@
1
- document.addEventListener('turbolinks:load', function () {
2
- var localeSelect = document.querySelectorAll('select[name=switch_to_locale]')
3
-
4
- if (localeSelect.length) {
5
- localeSelect.forEach(function (element) {
6
- element.addEventListener('change', function () {
7
- Spree.clearCache()
8
- Spree.showProgressBar()
9
- this.form.submit()
10
- })
11
- })
12
- }
13
- })
@@ -1,13 +0,0 @@
1
- Spree.ready(function () {
2
- return $('#currency').on('change', function() {
3
- return $.ajax({
4
- type: 'GET',
5
- url: $(this).data('href'),
6
- data: {
7
- currency: $(this).val()
8
- }
9
- }).done(function () {
10
- window.location.reload()
11
- })
12
- })
13
- })
@@ -1 +0,0 @@
1
- SpreeStorefrontConfig = YAML.load_file(Rails.root.join('config', 'spree_storefront.yml')).with_indifferent_access
@@ -1,99 +0,0 @@
1
- default:
2
- navigation:
3
- - title: Women
4
- subtitle: Categories
5
- url: /t/women
6
- items:
7
- - :title: Skirts
8
- :url: /t/women/skirts
9
- - :title: Dresses
10
- :url: /t/women/dresses
11
- - :title: Shirts and Blouses
12
- :url: /t/women/shirts-and-blouses
13
- - :title: Sweaters
14
- :url: /t/women/sweaters
15
- - :title: Tops and T-shirts
16
- :url: /t/women/tops-and-t-shirts
17
- - :title: Jackets and Coats
18
- :url: /t/women/jackets-and-coats
19
- promo_banners:
20
- - subtitle: New collection
21
- title: Summer 2021
22
- url: /t/new-collection/summer-2021
23
- image: 'meganav/promo_banner_left-first-category.jpg'
24
- - subtitle: Special Offers
25
- title: Get up to 30% off
26
- url: /t/special-offers/30-percent-off
27
- image: 'meganav/promo_banner_right-first-category.jpg'
28
- - title: Men
29
- subtitle: Categories
30
- url: /t/men
31
- items:
32
- - :title: Shirts
33
- :url: /t/men/shirts
34
- - :title: T-shirts
35
- :url: /t/men/t-shirts
36
- - :title: Sweaters
37
- :url: /t/men/sweaters
38
- - :title: Jackets and Coats
39
- :url: /t/men/jackets-and-coats
40
- promo_banners:
41
- - subtitle: New collection
42
- title: Summer 2021
43
- url: /t/new-collection/summer-2021
44
- image: 'meganav/promo_banner_left-second-category.jpg'
45
- - subtitle: Special Offers
46
- title: Get up to 30% off
47
- url: /t/special-offers/30-percent-off
48
- image: 'meganav/promo_banner_right-second-category.jpg'
49
- - title: Sportswear
50
- subtitle: Categories
51
- url: /t/sportswear
52
- items:
53
- - :title: Tops
54
- :url: /t/sportswear/tops
55
- - :title: Sweatshirts
56
- :url: /t/sportswear/sweatshirts
57
- - :title: Pants
58
- :url: /t/sportswear/pants
59
- promo_banners:
60
- - subtitle: New collection
61
- title: Summer 2021
62
- url: /t/new-collection/summer-2021
63
- image: 'meganav/promo_banner_left-third-category.jpg'
64
- - subtitle: Special Offers
65
- title: Get up to 30% off
66
- url: /t/special-offers/30-percent-off
67
- image: 'meganav/promo_banner_right-third-category.jpg'
68
- fr:
69
- navigation:
70
- - title: Femmes
71
- url: /fr/t/women
72
- promo_banners:
73
- - subtitle: Nouvelle collection
74
- title: Été 2021
75
- url: /fr/t/new-collection/summer-2021
76
- image: 'meganav/promo_banner_left-first-category.jpg'
77
- - subtitle: Offres spéciales
78
- url: /fr/t/special-offers/30-percent-off
79
- image: 'meganav/promo_banner_right-first-category.jpg'
80
- - title: Hommes
81
- url: /fr/t/men
82
- promo_banners:
83
- - subtitle: Nouvelle collection
84
- title: Été 2021
85
- url: /fr/t/new-collection/summer-2021
86
- image: 'meganav/promo_banner_left-second-category.jpg'
87
- - subtitle: Offres spéciales
88
- url: /fr/t/special-offers/30-percent-off
89
- image: 'meganav/promo_banner_right-second-category.jpg'
90
- - title: Vêtements de sport
91
- url: /fr/t/sportswear
92
- promo_banners:
93
- - subtitle: Nouvelle collection
94
- title: Été 2021
95
- url: /fr/t/new-collection/summer-2021
96
- image: 'meganav/promo_banner_left-third-category.jpg'
97
- - subtitle: Offres spéciales
98
- url: /fr/t/special-offers/30-percent-off
99
- image: 'meganav/promo_banner_right-third-category.jpg'