From 53c6be06b157761ce79ef4f0ce869d6f7c16682d Mon Sep 17 00:00:00 2001
From: "HATEC\\SPVDEV001" <tri.susilo@altama.co.id>
Date: Wed, 25 Oct 2023 10:01:49 +0700
Subject: set target blank

---
 src/lib/product/components/ProductCard.jsx | 28 ++++++++++++++++++++++------
 1 file changed, 22 insertions(+), 6 deletions(-)

(limited to 'src/lib/product/components/ProductCard.jsx')

diff --git a/src/lib/product/components/ProductCard.jsx b/src/lib/product/components/ProductCard.jsx
index 71466259..f7df29e2 100644
--- a/src/lib/product/components/ProductCard.jsx
+++ b/src/lib/product/components/ProductCard.jsx
@@ -103,7 +103,9 @@ const ProductCard = ({ product, simpleTitle, variant = 'vertical' }) => {
                 {product?.lowestPrice.priceDiscount > 0 ? (
                   currencyFormat(product?.lowestPrice.priceDiscount)
                 ) : (
-                  <a href={callForPriceWhatsapp}>Call for Inquiry</a>
+                  <a rel='noopener noreferrer' target='_blank' href={callForPriceWhatsapp}>
+                    Call for Inquiry
+                  </a>
                 )}
               </div>
             </>
@@ -118,7 +120,9 @@ const ProductCard = ({ product, simpleTitle, variant = 'vertical' }) => {
                   </div>
                 </>
               ) : (
-                <a href={callForPriceWhatsapp}>Call for Inquiry</a>
+                <a rel='noopener noreferrer' target='_blank' href={callForPriceWhatsapp}>
+                  Call for Inquiry
+                </a>
               )}
             </div>
           )}
@@ -126,7 +130,11 @@ const ProductCard = ({ product, simpleTitle, variant = 'vertical' }) => {
           <div className='flex w-full items-center gap-x-1 '>
             {product?.stockTotal > 0 && <div className='badge-solid-red'>Ready Stock</div>}
             {/* <div className='badge-gray'>{product?.stockTotal > 5 ? '> 5' : '< 5'}</div> */}
-            {product?.qtySold > 0 && <div className='text-gray_r-9 text-[11px]'>{sellingProductFormat(product?.qtySold) + ' Terjual'}</div>}
+            {product?.qtySold > 0 && (
+              <div className='text-gray_r-9 text-[11px]'>
+                {sellingProductFormat(product?.qtySold) + ' Terjual'}
+              </div>
+            )}
           </div>
         </div>
       </div>
@@ -206,7 +214,9 @@ const ProductCard = ({ product, simpleTitle, variant = 'vertical' }) => {
                 {product?.lowestPrice?.priceDiscount > 0 ? (
                   currencyFormat(product?.lowestPrice?.priceDiscount)
                 ) : (
-                  <a href={callForPriceWhatsapp}>Call for Inquiry</a>
+                  <a rel='noopener noreferrer' target='_blank' href={callForPriceWhatsapp}>
+                    Call for Inquiry
+                  </a>
                 )}
               </div>
             </>
@@ -221,7 +231,9 @@ const ProductCard = ({ product, simpleTitle, variant = 'vertical' }) => {
                   </div>
                 </>
               ) : (
-                <a href={callForPriceWhatsapp}>Call for Inquiry</a>
+                <a rel='noopener noreferrer' target='_blank' href={callForPriceWhatsapp}>
+                  Call for Inquiry
+                </a>
               )}
             </div>
           )}
@@ -229,7 +241,11 @@ const ProductCard = ({ product, simpleTitle, variant = 'vertical' }) => {
           <div className='flex w-full items-center gap-x-1 '>
             {product?.stockTotal > 0 && <div className='badge-solid-red'>Ready Stock</div>}
             {/* <div className='badge-gray'>{product?.stockTotal > 5 ? '> 5' : '< 5'}</div> */}
-            {product?.qtySold > 0 && <div className='text-gray_r-9 text-[11px]'>{sellingProductFormat(product?.qtySold) + ' Terjual'}</div>}
+            {product?.qtySold > 0 && (
+              <div className='text-gray_r-9 text-[11px]'>
+                {sellingProductFormat(product?.qtySold) + ' Terjual'}
+              </div>
+            )}
           </div>
         </div>
       </div>
-- 
cgit v1.2.3

