CartItem.vue 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. <template lang="pug">
  2. .cart-item
  3. h3.item-name {{ data.name }}
  4. input.item-quantity(type="text" value="1")
  5. span.item-x x
  6. span.item-price Gs {{ data.price }}
  7. span.item-equals =
  8. span.item-subtotal Gs {{ data.price }}
  9. </template>
  10. <script>
  11. export default {
  12. props: {
  13. data: {
  14. type: Object,
  15. default: () => {
  16. return {}
  17. }
  18. }
  19. }
  20. }
  21. </script>
  22. <style lang="sass">
  23. .cart-item
  24. width: 98%
  25. height: 85px
  26. border-bottom: 1px solid #d3d3d3
  27. .item-name
  28. width: 100%
  29. height: 15px
  30. margin: 5px
  31. float: left
  32. font:
  33. size: 11pt
  34. .item-quantity
  35. width: 50px
  36. height: 30px
  37. margin-top: 6px
  38. text-align: right
  39. float: left
  40. .item-x
  41. width: 20px
  42. height: 20px
  43. margin-top: 12px
  44. text-align: center
  45. float: left
  46. .item-price
  47. width: 80px
  48. height: 20px
  49. margin-top: 12px
  50. text-align: right
  51. float: left
  52. .item-equals
  53. width: 20px
  54. height: 20px
  55. margin-top: 12px
  56. text-align: center
  57. float: left
  58. .item-subtotal
  59. width: 100px
  60. height: 20px
  61. margin-top: 12px
  62. padding-right: 15px
  63. text-align: right
  64. float: right
  65. font-weight: bold
  66. </style>