@viur/shop-components 0.14.1 → 0.14.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@viur/shop-components",
3
- "version": "0.14.1",
3
+ "version": "0.14.3",
4
4
  "description": "Frontend Vue components for the shop module of ViUR",
5
5
  "repository": {
6
6
  "type": "git",
@@ -40,7 +40,7 @@
40
40
 
41
41
  <div class="viur-shop-cart-sidebar-info viur-shop-cart-sidebar-info--total">
42
42
  <span v-html="$t('viur.shop.summary_total')"></span>
43
- <sl-format-number lang="de" type="currency" currency="EUR" :value="state.total_discount_price">
43
+ <sl-format-number lang="de" type="currency" currency="EUR" :value="state.total">
44
44
  </sl-format-number>
45
45
  </div>
46
46
  <div class="viur-shop-cart-sidebar-info " v-for="vatObj in state.vat">
@@ -85,6 +85,7 @@ const props = defineProps({
85
85
  const state = reactive({
86
86
  items: computed(() => { return shopStore.state.cartList }),
87
87
  cartTotal: computed(() => {
88
+ // TODO: Why isn't total_raw used? :: return shopStore.state.cartRoot.total_raw
88
89
  let sum = state.items.reduce((acc,item)=>{
89
90
  if (item.skel_type==="leaf"){
90
91
  acc+=item.price.current *item.quantity
@@ -114,7 +115,7 @@ const state = reactive({
114
115
  }),
115
116
  discount:computed(()=> (state.cartTotal - shopStore.state.cartRoot.total_discount_price)*-1),
116
117
  total: computed(() => {
117
- return shopStore.state.cartRoot.total
118
+ return shopStore.state.cartRoot.total_discount_price
118
119
  }),
119
120
  vat:computed(()=>{
120
121
  return shopStore.state.cartRoot.vat
@@ -74,7 +74,7 @@
74
74
  <div class="availability"
75
75
  :class="`availability--${item.shop_availability}`"
76
76
  >
77
- {{$t(item.shop_availability)}}
77
+ <span class="availability-description">{{$t(item.shop_availability)}}</span>
78
78
  </div>
79
79
  </div>
80
80
 
@@ -142,12 +142,19 @@ function removeArticle(){
142
142
  display: block;
143
143
  background-color: #666;
144
144
  width: .7em;
145
+ min-width: .7em;
145
146
  height: .7em;
146
147
  border-radius: 50%;
147
148
  margin-right: 5px;
148
149
  margin-bottom: 2px;
149
150
  }
150
151
  }
152
+ .availability-description {
153
+ min-width: 0;
154
+ white-space: nowrap;
155
+ overflow: hidden;
156
+ text-overflow: ellipsis;
157
+ }
151
158
  .availability--onrequest,
152
159
  .availability--instock {
153
160
  color: var(--ignt-color-success);
@@ -31,12 +31,13 @@ function close(){
31
31
 
32
32
  <style scoped>
33
33
 
34
- .decent{
34
+ .decent {
35
35
  margin: 0;
36
36
  transition: all ease .3s;
37
37
 
38
38
  &::part(base){
39
- border: none;
39
+ border: none;
40
+ border-radius: 0;
40
41
  }
41
42
 
42
43
  &::part(label){
@@ -46,4 +47,4 @@ function close(){
46
47
  }
47
48
  }
48
49
 
49
- </style>
50
+ </style>