Advertisement
prashandip

foeveryng_Product

Feb 26th, 2021 (edited)
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.09 KB | None | 0 0
  1. <!-- Nunito Font -->
  2. <link rel="preconnect" href="https://fonts.gstatic.com" />
  3. <link
  4. href="https://fonts.googleapis.com/css2?family=Nunito:wght@200;300;400;600;700;800;900&display=swap"
  5. rel="stylesheet"
  6. />
  7. <!-- Fontawesome -->
  8. <link
  9. rel="stylesheet"
  10. href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.2/css/all.min.css"
  11. integrity="sha512-HK5fgLBL+xu6dm/Ii3z4xhlSUyZgTT9tuc/hSrtw6uzJOvgRr2a9jyxxT1ely+B+xFAmJKVSTbpM/CuL7qxO8w=="
  12. crossorigin="anonymous"
  13. />
  14.  
  15. <!---------------------------------------------------------------------------------------------->
  16.  
  17. <template>
  18. <div class="product-wrapper">
  19. <v-img
  20. contain
  21. height="150"
  22. src="https://pngimg.com/uploads/lipstick/lipstick_PNG23968.png"
  23. ></v-img>
  24. <p style="font-weight: 700" class="my-3">
  25. The Red Lipstick that everyone wants to own
  26. </p>
  27. <div class="d-flex row align-center px-1">
  28. <v-rating
  29. background-color="warning lighten-2"
  30. color="warning"
  31. hover
  32. length="5"
  33. size="20"
  34. value="3"
  35. ></v-rating>
  36. <span style="color: #a8a8a8" class="pl-2">(12)</span>
  37. </div>
  38. <p style="font-weight: 800" class="mt-3 mb-2">Rs. 1,350</p>
  39. <div class="d-flex row px-3 justify-space-between align-center">
  40. <span
  41. style="
  42. text-decoration: line-through;
  43. font-weight: 300;
  44. font-size: 0.9em;
  45. color: darkslategray;
  46. "
  47. >Rs. 1,500</span
  48. >
  49. <span style="color: #ed7a9b">10% off</span>
  50. </div>
  51. <div class="d-flex row justify-space-between align-center pa-3">
  52. <div
  53. style="
  54. background: #e0e0e0;
  55. color: #4682b4;
  56. font-weight: 600;
  57. padding: 4px 20px;
  58. border-radius: 20px;
  59. cursor: pointer;
  60. "
  61. >
  62. Add To Cart
  63. </div>
  64. <div v-on:click="toggleIcon" style="" class="heart-btn">
  65. <i
  66. class="far fa-heart heart"
  67. v-bind:class="{ heart_active: isActive, fas: isActive }"
  68. ></i>
  69. </div>
  70. </div>
  71. </div>
  72. </template>
  73.  
  74. <script>
  75. export default {
  76. name: "Product",
  77. data() {
  78. return {
  79. isActive: false,
  80. };
  81. },
  82. methods: {
  83. toggleIcon: function () {
  84. this.isActive = !this.isActive;
  85. },
  86. },
  87. };
  88. </script>
  89.  
  90. <style scoped lang="scss">
  91. .product-wrapper {
  92. font-family: "Nunito", sans-serif;
  93. box-shadow: 0 0 20px #aaaaaa70;
  94. margin: 10px;
  95. padding: 10px;
  96. border-radius: 10px;
  97. display: flex;
  98. flex-direction: column;
  99. justify-content: flex-start;
  100. }
  101. .heart-btn {
  102. position: relative;
  103. background: lighten(#e0e0e0, 5%);
  104. border-radius: 50%;
  105. height: 30px;
  106. width: 30px;
  107. cursor: pointer;
  108. }
  109. .heart {
  110. transition: 0.3s;
  111. color: #e63e62;
  112. position: absolute;
  113. font-size: 1.1em;
  114. top: 50%;
  115. left: 50%;
  116. transform: translate(-50%, -45%);
  117. }
  118. .heart_active {
  119. filter: drop-shadow(3px 3px 6px gray);
  120. font-size: 1em !important;
  121. transform: translate(-50%, -42%) !important;
  122. }
  123. </style>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement