negodesign 0.0.77 → 0.0.79
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/README.md +133 -133
- package/dist/components/NegoDesign.svelte +21 -21
- package/dist/components/pages/admin/01/ui/AdminContent.svelte +14 -14
- package/dist/components/pages/admin/01/ui/AdminPanel.svelte +46 -46
- package/dist/components/pages/product-details/shared/ProductDetailFilesVertical.svelte +103 -103
- package/dist/components/pages/profile-user/shared/ProfileUserAddress.svelte +83 -83
- package/dist/components/pages/profile-user/shared/ProfileUserTabs.svelte +80 -80
- package/dist/components/pages/security/auth/PageAuth01.svelte +21 -24
- package/dist/components/pages/security/auth/PageAuth02.svelte +11 -16
- package/dist/components/pages/security/auth/PageAuth03.svelte +11 -16
- package/dist/components/pages/security/login/01/ui/FormLogin.svelte +7 -5
- package/dist/components/pages/security/login/01/ui/FormLogin.svelte.d.ts +2 -0
- package/dist/components/pages/security/login/01/ui/FormLoginEmailPassword.svelte +4 -2
- package/dist/components/pages/security/login/01/ui/FormLoginEmailPassword.svelte.d.ts +2 -0
- package/dist/components/pages/security/login/01/ui/FormLoginPhonePassword.svelte +4 -2
- package/dist/components/pages/security/login/01/ui/FormLoginPhonePassword.svelte.d.ts +2 -0
- package/dist/components/pages/security/login/01/ui/FormLoginUsernamePassword.svelte +4 -2
- package/dist/components/pages/security/login/01/ui/FormLoginUsernamePassword.svelte.d.ts +2 -0
- package/dist/components/pages/security/login/01/ui/{LoginCard.svelte → LoginCard01.svelte} +132 -109
- package/dist/components/pages/security/login/01/ui/{LoginCard.svelte.d.ts → LoginCard01.svelte.d.ts} +3 -3
- package/dist/components/pages/security/login/01/ui/PageLogin01.svelte +2 -2
- package/dist/components/pages/security/login/02/ui/FormLogin02.svelte +7 -5
- package/dist/components/pages/security/login/02/ui/FormLogin02.svelte.d.ts +2 -0
- package/dist/components/pages/security/login/02/ui/FormLoginEmailPassword02.svelte +4 -2
- package/dist/components/pages/security/login/02/ui/FormLoginEmailPassword02.svelte.d.ts +2 -0
- package/dist/components/pages/security/login/02/ui/FormLoginPhonePassword02.svelte +4 -2
- package/dist/components/pages/security/login/02/ui/FormLoginPhonePassword02.svelte.d.ts +2 -0
- package/dist/components/pages/security/login/02/ui/FormLoginUsernamePassword02.svelte +4 -2
- package/dist/components/pages/security/login/02/ui/FormLoginUsernamePassword02.svelte.d.ts +2 -0
- package/dist/components/pages/security/login/03/ui/FormLogin03.svelte +8 -4
- package/dist/components/pages/security/login/03/ui/FormLogin03.svelte.d.ts +2 -0
- package/dist/components/pages/security/login/03/ui/FormLoginEmailPassword03.svelte +4 -2
- package/dist/components/pages/security/login/03/ui/FormLoginEmailPassword03.svelte.d.ts +2 -0
- package/dist/components/pages/security/login/03/ui/FormLoginPhonePassword03.svelte +4 -2
- package/dist/components/pages/security/login/03/ui/FormLoginPhonePassword03.svelte.d.ts +2 -0
- package/dist/components/pages/security/login/03/ui/FormLoginUsernamePassword03.svelte +4 -2
- package/dist/components/pages/security/login/03/ui/FormLoginUsernamePassword03.svelte.d.ts +2 -0
- package/dist/components/pages/security/login/PageLogin.svelte +30 -30
- package/dist/components/pages/security/register/01/ui/PageRegister01.svelte +21 -9
- package/dist/components/pages/security/register/01/ui/PageRegister01.svelte.d.ts +1 -0
- package/dist/components/pages/security/register/01/ui/{RegisterCard.svelte → RegisterCard01.svelte} +26 -22
- package/dist/components/pages/security/register/01/ui/{RegisterCard.svelte.d.ts → RegisterCard01.svelte.d.ts} +3 -3
- package/dist/components/pages/security/register/FormRegister.svelte +40 -14
- package/dist/components/pages/security/register/FormRegister.svelte.d.ts +3 -0
- package/dist/components/ui/avatar/avatar-fallback.svelte +29 -29
- package/dist/components/ui/avatar/avatar-image.svelte +38 -38
- package/dist/components/ui/avatar/avatar.svelte +39 -39
- package/dist/components/ui/badge/badge.svelte +46 -46
- package/dist/components/ui/banner/AdCardBanner.svelte +74 -74
- package/dist/components/ui/banner/CtaCardBanner.svelte +118 -118
- package/dist/components/ui/banner/CtaCardImageBanner.svelte +94 -94
- package/dist/components/ui/breadcrumb/core/breadcrumb-list.svelte +31 -31
- package/dist/components/ui/button/ButtonBack.svelte +18 -18
- package/dist/components/ui/button/ButtonLogin.svelte +15 -15
- package/dist/components/ui/button/ButtonLoginWith.svelte +57 -57
- package/dist/components/ui/button/ButtonSend.svelte +15 -15
- package/dist/components/ui/button/button.svelte +85 -85
- package/dist/components/ui/card/core/highlight/01/CardHighlight01.svelte +103 -103
- package/dist/components/ui/card/core/highlight/02/CardHighlight02.svelte +99 -99
- package/dist/components/ui/card/core/highlight/CardHighlight.svelte +22 -22
- package/dist/components/ui/card/core/media/01/CardMedia01.svelte +133 -133
- package/dist/components/ui/card/core/media/02/CardMedia02.svelte +127 -127
- package/dist/components/ui/card/core/media/CardMedia.svelte +18 -18
- package/dist/components/ui/card/core/product/01/CardProduct01.svelte +136 -136
- package/dist/components/ui/card/core/product/02/CardProduct02.svelte +124 -124
- package/dist/components/ui/card/core/product/CardProduct.svelte +22 -22
- package/dist/components/ui/card/core/profile/01/CardProfile01.svelte +134 -134
- package/dist/components/ui/card/core/profile/02/CardProfile02.svelte +132 -132
- package/dist/components/ui/card/core/profile/CardProfile.svelte +18 -18
- package/dist/components/ui/card/core/promotion/CardPromotion.svelte +139 -139
- package/dist/components/ui/card/core/promotion/CardPromotionPrice.svelte +32 -32
- package/dist/components/ui/card/core/shared/CardButton.svelte +42 -42
- package/dist/components/ui/card/core/shared/CardCart.svelte +36 -36
- package/dist/components/ui/card/core/shared/CardDescription.svelte +41 -41
- package/dist/components/ui/card/core/shared/CardFavorite.svelte +33 -33
- package/dist/components/ui/card/core/shared/CardLogo.svelte +19 -19
- package/dist/components/ui/card/core/shared/CardPhoneOrWhatsapp.svelte +45 -45
- package/dist/components/ui/card/core/shared/CardStarRating.svelte +24 -24
- package/dist/components/ui/card/core/shared/CardTags.svelte +95 -95
- package/dist/components/ui/card/core/shared/CardThumbnailVideo.svelte +232 -232
- package/dist/components/ui/card/core/shared/CardTitlePrice.svelte +24 -24
- package/dist/components/ui/card/core/shared/TruncatableText.svelte +49 -49
- package/dist/components/ui/carousel/carousel-content.svelte +56 -56
- package/dist/components/ui/carousel/carousel-item.svelte +29 -29
- package/dist/components/ui/carousel/carousel-next.svelte +40 -40
- package/dist/components/ui/carousel/carousel-previous.svelte +40 -40
- package/dist/components/ui/carousel/carousel.svelte +225 -225
- package/dist/components/ui/carousel/core/badge/ui/CarouselBadge.svelte +108 -108
- package/dist/components/ui/carousel/core/grid/shared/ui/CarouselGridSlot.svelte +38 -38
- package/dist/components/ui/carousel/core/hero/ui/CarouselHero.svelte +181 -181
- package/dist/components/ui/carousel/core/highlights/ui/CarouselHighlights.svelte +67 -67
- package/dist/components/ui/carousel/core/product/ui/CarouselProduct.svelte +57 -57
- package/dist/components/ui/carousel/core/promotion/ui/CarouselPromotion.svelte +67 -67
- package/dist/components/ui/carousel/core/shared/ui/CarouselHeader.svelte +59 -59
- package/dist/components/ui/checkbox/checkbox.svelte +96 -96
- package/dist/components/ui/collapsible/collapsible-content.svelte +30 -30
- package/dist/components/ui/collapsible/collapsible-trigger.svelte +51 -51
- package/dist/components/ui/collapsible/collapsible.svelte +66 -66
- package/dist/components/ui/data-table/flex-render.svelte +40 -40
- package/dist/components/ui/datatable/ui/DataTableActions.svelte +28 -28
- package/dist/components/ui/datatable/ui/DataTableCheckbox.svelte +22 -22
- package/dist/components/ui/datatable/ui/DataTableContent.svelte +59 -59
- package/dist/components/ui/datatable/ui/DataTableCore.svelte +148 -148
- package/dist/components/ui/datatable/ui/DataTableDragHandle.svelte +8 -8
- package/dist/components/ui/datatable/ui/DataTableListFilter.svelte +60 -60
- package/dist/components/ui/datatable/ui/DataTableListPagination.svelte +35 -35
- package/dist/components/ui/drawer/drawer-close.svelte +41 -41
- package/dist/components/ui/drawer/drawer-content.svelte +81 -81
- package/dist/components/ui/drawer/drawer-description.svelte +19 -19
- package/dist/components/ui/drawer/drawer-footer.svelte +20 -20
- package/dist/components/ui/drawer/drawer-header.svelte +20 -20
- package/dist/components/ui/drawer/drawer-nested.svelte +34 -34
- package/dist/components/ui/drawer/drawer-overlay.svelte +25 -25
- package/dist/components/ui/drawer/drawer-portal.svelte +19 -19
- package/dist/components/ui/drawer/drawer-title.svelte +19 -19
- package/dist/components/ui/drawer/drawer-trigger.svelte +42 -42
- package/dist/components/ui/drawer/drawer.svelte +74 -74
- package/dist/components/ui/dropdown-menu/dropdown-menu-checkbox-group.svelte +25 -25
- package/dist/components/ui/dropdown-menu/dropdown-menu-checkbox-item.svelte +69 -69
- package/dist/components/ui/dropdown-menu/dropdown-menu-content.svelte +106 -106
- package/dist/components/ui/dropdown-menu/dropdown-menu-group-heading.svelte +27 -27
- package/dist/components/ui/dropdown-menu/dropdown-menu-group.svelte +21 -21
- package/dist/components/ui/dropdown-menu/dropdown-menu-item.svelte +60 -60
- package/dist/components/ui/dropdown-menu/dropdown-menu-label.svelte +27 -27
- package/dist/components/ui/dropdown-menu/dropdown-menu-portal.svelte +6 -6
- package/dist/components/ui/dropdown-menu/dropdown-menu-radio-group.svelte +43 -43
- package/dist/components/ui/dropdown-menu/dropdown-menu-radio-item.svelte +70 -70
- package/dist/components/ui/dropdown-menu/dropdown-menu-separator.svelte +20 -20
- package/dist/components/ui/dropdown-menu/dropdown-menu-sub-content.svelte +33 -33
- package/dist/components/ui/dropdown-menu/dropdown-menu-sub-trigger.svelte +57 -57
- package/dist/components/ui/dropdown-menu/dropdown-menu-sub.svelte +76 -76
- package/dist/components/ui/dropdown-menu/dropdown-menu-trigger.svelte +68 -68
- package/dist/components/ui/dropdown-menu/dropdown-menu.svelte +53 -53
- package/dist/components/ui/empty/empty-content.svelte +19 -19
- package/dist/components/ui/empty/empty-description.svelte +19 -19
- package/dist/components/ui/empty/empty-header.svelte +19 -19
- package/dist/components/ui/empty/empty-media.svelte +41 -41
- package/dist/components/ui/empty/empty-title.svelte +19 -19
- package/dist/components/ui/empty/empty.svelte +19 -19
- package/dist/components/ui/footer/ui/Footer.svelte +18 -18
- package/dist/components/ui/form/data/InputIconDefault.svelte.js +2 -1
- package/dist/components/ui/form/data/InputLabel.svelte.d.ts +3 -0
- package/dist/components/ui/form/ui/calendar/Calendar.svelte +194 -0
- package/dist/components/ui/form/ui/calendar/Calendar.svelte.d.ts +15 -0
- package/dist/components/ui/form/ui/calendar/CalendarCard.svelte +90 -0
- package/dist/components/ui/form/ui/calendar/CalendarCard.svelte.d.ts +20 -0
- package/dist/components/ui/form/ui/calendar/DaysGrid.svelte +76 -0
- package/dist/components/ui/form/ui/calendar/DaysGrid.svelte.d.ts +17 -0
- package/dist/components/ui/form/ui/calendar/MonthSelect.svelte +50 -0
- package/dist/components/ui/form/ui/calendar/MonthSelect.svelte.d.ts +10 -0
- package/dist/components/ui/form/ui/calendar/YearSelect.svelte +117 -0
- package/dist/components/ui/form/ui/calendar/YearSelect.svelte.d.ts +15 -0
- package/dist/components/ui/form/ui/calendar/index.d.ts +5 -0
- package/dist/components/ui/form/ui/calendar/index.js +5 -0
- package/dist/components/ui/form/ui/calendar/utils.d.ts +26 -0
- package/dist/components/ui/form/ui/calendar/utils.js +89 -0
- package/dist/components/ui/form/ui/input-base.svelte +83 -81
- package/dist/components/ui/form/ui/input-calendar-interval.svelte +179 -0
- package/dist/components/ui/form/ui/input-calendar-interval.svelte.d.ts +14 -0
- package/dist/components/ui/form/ui/input-calendar.svelte +110 -0
- package/dist/components/ui/form/ui/input-calendar.svelte.d.ts +9 -0
- package/dist/components/ui/form/ui/input-email-or-phone.svelte +23 -23
- package/dist/components/ui/form/ui/input-email.svelte +23 -23
- package/dist/components/ui/form/ui/input-password-confirm.svelte +23 -23
- package/dist/components/ui/form/ui/input-password.svelte +23 -23
- package/dist/components/ui/form/ui/input-phone.svelte +37 -33
- package/dist/components/ui/form/ui/input-select.svelte +210 -158
- package/dist/components/ui/form/ui/input-select.svelte.d.ts +5 -9
- package/dist/components/ui/form/ui/input-username.svelte +22 -22
- package/dist/components/ui/grid/core/ui/01/Grid01.svelte +30 -30
- package/dist/components/ui/grid/core/ui/02/Grid02.svelte +30 -30
- package/dist/components/ui/grid/core/ui/ItemsPanel.svelte +26 -26
- package/dist/components/ui/grid/core/ui/ItemsPanelCarousel.svelte +37 -37
- package/dist/components/ui/grid/core/ui/ItemsPanelGrid.svelte +43 -43
- package/dist/components/ui/grid/core/ui/ItemsSimpleGrid.svelte +45 -45
- package/dist/components/ui/grid/core/ui/shared/DescriptionGrid.svelte +23 -23
- package/dist/components/ui/grid/core/ui/shared/IconRenderGrid.svelte +23 -23
- package/dist/components/ui/grid/core/ui/shared/TitleGrid.svelte +19 -19
- package/dist/components/ui/hero/SimpleHero.svelte +65 -65
- package/dist/components/ui/input-otp/input-otp-group.svelte +22 -22
- package/dist/components/ui/input-otp/input-otp-separator.svelte +27 -27
- package/dist/components/ui/input-otp/input-otp-slot.svelte +63 -63
- package/dist/components/ui/input-otp/input-otp.svelte +181 -181
- package/dist/components/ui/label/core/LabelOr.svelte +25 -25
- package/dist/components/ui/label/label.svelte +19 -19
- package/dist/components/ui/language-switcher/language-switcher.svelte +48 -48
- package/dist/components/ui/light-switch/light-switch.svelte +48 -48
- package/dist/components/ui/link/link-forget-password.svelte +12 -12
- package/dist/components/ui/link/link-privacy-polity.svelte +12 -12
- package/dist/components/ui/link/link-terms-of-service.svelte +12 -12
- package/dist/components/ui/modal/core/index.d.ts +1 -1
- package/dist/components/ui/modal/core/types.d.ts +2 -1
- package/dist/components/ui/modal/core/ui/ModalCore.svelte +132 -132
- package/dist/components/ui/modal/grid/types.d.ts +6 -5
- package/dist/components/ui/modal/grid/ui/02/ModalGridSelection02.svelte +146 -146
- package/dist/components/ui/modal/share/ui/ModalShareSelection.svelte +156 -156
- package/dist/components/ui/nav/ui/ComplexMenu.svelte +51 -51
- package/dist/components/ui/nav/ui/Menu.svelte +72 -72
- package/dist/components/ui/nav/ui/SimpleMenu.svelte +14 -14
- package/dist/components/ui/nav/ui/mobile/ComplexMenuMobile.svelte +125 -125
- package/dist/components/ui/nav/ui/mobile/MenuMobile.svelte +54 -54
- package/dist/components/ui/nav/ui/shared/MenuButton.svelte +51 -51
- package/dist/components/ui/nav/ui/shared/MenuLinks.svelte +40 -40
- package/dist/components/ui/nav/ui/shared/MenuListItem.svelte +44 -44
- package/dist/components/ui/nav/ui/shared/MenuLogo.svelte +13 -13
- package/dist/components/ui/nav/ui/shared/dropdown/DropdownNavigationMenuItemGrid.svelte +30 -30
- package/dist/components/ui/nav/ui/shared/navigation/NavDropdown.svelte +87 -87
- package/dist/components/ui/nav/ui/shared/navigation/NavigationMenuItem.svelte +17 -17
- package/dist/components/ui/nav/ui/shared/navigation/NavigationMenuItemCard.svelte +53 -53
- package/dist/components/ui/nav/ui/shared/navigation/NavigationMenuItemGrid.svelte +36 -36
- package/dist/components/ui/nav/ui/shared/navigation/NavigationMenuItemList.svelte +24 -24
- package/dist/components/ui/nav/ui/shared/navigation/NavigationMenuItems.svelte +21 -21
- package/dist/components/ui/panel/CarouselSlot.svelte +57 -57
- package/dist/components/ui/panel/LeftHero.svelte +114 -114
- package/dist/components/ui/panel/NotFoundEmpty.svelte +66 -66
- package/dist/components/ui/phone-input/country-selector.svelte +87 -87
- package/dist/components/ui/phone-input/country-selector.svelte.d.ts +2 -2
- package/dist/components/ui/phone-input/flag.svelte +11 -11
- package/dist/components/ui/phone-input/phone-input.svelte +163 -148
- package/dist/components/ui/phone-input/phone-input.svelte.d.ts +2 -2
- package/dist/components/ui/popover/popover-close.svelte +25 -25
- package/dist/components/ui/popover/popover-content.svelte +92 -92
- package/dist/components/ui/popover/popover-portal.svelte +6 -6
- package/dist/components/ui/popover/popover-trigger.svelte +68 -68
- package/dist/components/ui/popover/popover.svelte +53 -53
- package/dist/components/ui/search/SearchInput.svelte +32 -32
- package/dist/components/ui/search/shared/SearchInputCore.svelte +66 -66
- package/dist/components/ui/separator/separator.svelte +28 -28
- package/dist/components/ui/sidebar/core/MenuBarSidebar.svelte +70 -70
- package/dist/components/ui/sidebar/core/ui/navbar/NavMenuBarSidebar.svelte +97 -97
- package/dist/components/ui/sidebar/core/ui/navbar/NavMenuBottomSidebar.svelte +33 -33
- package/dist/components/ui/sidebar/core/ui/navbar/NavMenuTopBarSidebar.svelte +101 -101
- package/dist/components/ui/sidebar/core/ui/navbar/nav-menu-header-sidebar.svelte +77 -77
- package/dist/components/ui/sidebar/sidebar-content.svelte +24 -24
- package/dist/components/ui/sidebar/sidebar-footer.svelte +21 -21
- package/dist/components/ui/sidebar/sidebar-group-content.svelte +21 -21
- package/dist/components/ui/sidebar/sidebar-menu-action.svelte +38 -38
- package/dist/components/ui/sidebar/sidebar-menu-button.svelte +70 -70
- package/dist/components/ui/sidebar/sidebar-menu-sub-button.svelte +39 -39
- package/dist/components/ui/sidebar/sidebar-provider.svelte +62 -62
- package/dist/components/ui/sidebar/sidebar-rail.svelte +36 -36
- package/dist/components/ui/sidebar/sidebar-separator.svelte +21 -21
- package/dist/components/ui/sidebar/sidebar-trigger.svelte +36 -36
- package/dist/components/ui/sidebar/sidebar.svelte +118 -118
- package/dist/components/ui/skeleton/skeleton.svelte +19 -19
- package/dist/components/ui/star-rating/star-rating-star.svelte +66 -66
- package/dist/components/ui/star-rating/star-rating.svelte +149 -149
- package/dist/components/ui/table/table-body.svelte +15 -15
- package/dist/components/ui/table/table-caption.svelte +20 -20
- package/dist/components/ui/table/table-cell.svelte +15 -15
- package/dist/components/ui/table/table-footer.svelte +20 -20
- package/dist/components/ui/table/table-head.svelte +15 -15
- package/dist/components/ui/table/table-header.svelte +20 -20
- package/dist/components/ui/table/table-row.svelte +15 -15
- package/dist/components/ui/table/table.svelte +17 -17
- package/dist/components/ui/tabs/ui/tab-underline.svelte +43 -43
- package/dist/components/ui/underline-tabs/underline-tabs-content.svelte +33 -33
- package/dist/components/ui/underline-tabs/underline-tabs-list.svelte +40 -40
- package/dist/components/ui/underline-tabs/underline-tabs-trigger.svelte +91 -91
- package/dist/components/ui/underline-tabs/underline-tabs.svelte +61 -61
- package/dist/docs/ApiTable.svelte +42 -42
- package/dist/docs/CodeBlock.svelte +26 -26
- package/dist/docs/DocsHeader.svelte +25 -25
- package/dist/docs/DocsSidebar.svelte +108 -156
- package/dist/docs/components.js +638 -563
- package/dist/globals.css +68 -10
- package/dist/i18n/langs/en.d.ts +7 -0
- package/dist/i18n/langs/en.js +7 -0
- package/dist/i18n/langs/pt.d.ts +7 -0
- package/dist/i18n/langs/pt.js +7 -0
- package/dist/i18n/translations.d.ts +14 -0
- package/dist/index.d.ts +23 -0
- package/dist/index.js +23 -0
- package/dist/styles/globals.css +283 -283
- package/dist/types/index.d.ts +3 -1
- package/package.json +81 -81
- package/dist/components/pages/security/login/01/ui/FormRegister.svelte +0 -28
- package/dist/components/pages/security/login/01/ui/FormRegister.svelte.d.ts +0 -3
|
@@ -1,127 +1,127 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
/**
|
|
3
|
-
* Card component with a title and content.
|
|
4
|
-
* @component
|
|
5
|
-
*/
|
|
6
|
-
import { InformationCircleIcon, UserIcon } from "@hugeicons/core-free-icons";
|
|
7
|
-
import { t } from "../../../../../../i18n";
|
|
8
|
-
import type { CardMediaProps } from "../../types";
|
|
9
|
-
import CardStarRating from "../../shared/CardStarRating.svelte";
|
|
10
|
-
import CardTags from "../../shared/CardTags.svelte";
|
|
11
|
-
import CardDescription from "../../shared/CardDescription.svelte";
|
|
12
|
-
import CardThumbnailVideo from "../../shared/CardThumbnailVideo.svelte";
|
|
13
|
-
import CardButton from "../../shared/CardButton.svelte";
|
|
14
|
-
import CardFavorite from "../../shared/CardFavorite.svelte";
|
|
15
|
-
import Skeleton from "../../../../skeleton/skeleton.svelte";
|
|
16
|
-
import CardLogo from "../../shared/CardLogo.svelte";
|
|
17
|
-
let {
|
|
18
|
-
id,
|
|
19
|
-
tags,
|
|
20
|
-
logo,
|
|
21
|
-
title,
|
|
22
|
-
content,
|
|
23
|
-
className,
|
|
24
|
-
imageUrl,
|
|
25
|
-
videoUrl,
|
|
26
|
-
startNumber,
|
|
27
|
-
startMax = 5,
|
|
28
|
-
isImageButtonMaximized = false,
|
|
29
|
-
isVideoButtonMaximized = false,
|
|
30
|
-
isTagBorderBottom = false,
|
|
31
|
-
isFavorite = false,
|
|
32
|
-
isLoading = false,
|
|
33
|
-
buttonProfileClass,
|
|
34
|
-
buttonDetailsClass,
|
|
35
|
-
isDescriptionIcon,
|
|
36
|
-
isDescriptionLabel,
|
|
37
|
-
onFavoriteClick,
|
|
38
|
-
onButtonProfile,
|
|
39
|
-
onButtonDetails,
|
|
40
|
-
}: CardMediaProps = $props();
|
|
41
|
-
|
|
42
|
-
let isShowButtonProfileAndDetails = $derived(
|
|
43
|
-
onButtonProfile != null && onButtonDetails != null,
|
|
44
|
-
);
|
|
45
|
-
</script>
|
|
46
|
-
|
|
47
|
-
<article
|
|
48
|
-
class="border border-gray-300 dark:border-gray-700 bg-gray-100 dark:bg-transparent rounded-lg p-5 space-y-1 md:space-y-3 {className}"
|
|
49
|
-
>
|
|
50
|
-
<div class="flex flex-col justify-center items-center w-full relative">
|
|
51
|
-
<div class="flex flex-col justify-start gap-2">
|
|
52
|
-
<div class="flex justify-center items-center">
|
|
53
|
-
<CardLogo {logo} {isLoading} />
|
|
54
|
-
</div>
|
|
55
|
-
<div class="flex flex-col justify-center items-center">
|
|
56
|
-
{#if title}
|
|
57
|
-
<div class="text-center font-bold text-lg">{title}</div>
|
|
58
|
-
{:else if isLoading}
|
|
59
|
-
<Skeleton class="w-40 h-5 rounded-lg bg-gray-400 mb-0.5" />
|
|
60
|
-
{/if}
|
|
61
|
-
|
|
62
|
-
{#if startNumber}
|
|
63
|
-
<CardStarRating {startNumber} {startMax} {isLoading} />
|
|
64
|
-
{:else if isLoading}
|
|
65
|
-
<Skeleton class="w-20 h-4 rounded-lg bg-gray-300 mt-0.5" />
|
|
66
|
-
{/if}
|
|
67
|
-
</div>
|
|
68
|
-
</div>
|
|
69
|
-
<div class="flex justify-end items-center absolute top-0 right-0">
|
|
70
|
-
<CardFavorite
|
|
71
|
-
{id}
|
|
72
|
-
{isFavorite}
|
|
73
|
-
onFavoriteClick={() => onFavoriteClick!(id)}
|
|
74
|
-
{isLoading}
|
|
75
|
-
/>
|
|
76
|
-
</div>
|
|
77
|
-
<CardTags tags={tags ?? []} {isTagBorderBottom} {isLoading} />
|
|
78
|
-
</div>
|
|
79
|
-
|
|
80
|
-
<div class="h-24">
|
|
81
|
-
<CardDescription
|
|
82
|
-
{content}
|
|
83
|
-
{isLoading}
|
|
84
|
-
{isDescriptionIcon}
|
|
85
|
-
{isDescriptionLabel}
|
|
86
|
-
/>
|
|
87
|
-
</div>
|
|
88
|
-
|
|
89
|
-
<CardThumbnailVideo
|
|
90
|
-
{imageUrl}
|
|
91
|
-
{videoUrl}
|
|
92
|
-
{isImageButtonMaximized}
|
|
93
|
-
{isVideoButtonMaximized}
|
|
94
|
-
{isLoading}
|
|
95
|
-
/>
|
|
96
|
-
|
|
97
|
-
{#if onButtonProfile || onButtonDetails}
|
|
98
|
-
<div class="flex justify-center items-center gap-2 mt-4 w-full">
|
|
99
|
-
{#if onButtonProfile}
|
|
100
|
-
<CardButton
|
|
101
|
-
{id}
|
|
102
|
-
icon={UserIcon}
|
|
103
|
-
className={buttonProfileClass}
|
|
104
|
-
text={$t("label.view.profile")}
|
|
105
|
-
onClick={onButtonProfile}
|
|
106
|
-
isFlex={isShowButtonProfileAndDetails}
|
|
107
|
-
{isLoading}
|
|
108
|
-
/>
|
|
109
|
-
{:else if isLoading}
|
|
110
|
-
<Skeleton class="w-20 h-4 rounded-lg bg-gray-400 mt-0.5" />
|
|
111
|
-
{/if}
|
|
112
|
-
{#if onButtonDetails}
|
|
113
|
-
<CardButton
|
|
114
|
-
{id}
|
|
115
|
-
icon={InformationCircleIcon}
|
|
116
|
-
className={buttonDetailsClass}
|
|
117
|
-
text={$t("label.more.details")}
|
|
118
|
-
onClick={onButtonDetails}
|
|
119
|
-
isFlex={isShowButtonProfileAndDetails}
|
|
120
|
-
{isLoading}
|
|
121
|
-
/>
|
|
122
|
-
{:else if isLoading}
|
|
123
|
-
<Skeleton class="w-20 h-4 rounded-lg bg-gray-400 mt-0.5" />
|
|
124
|
-
{/if}
|
|
125
|
-
</div>
|
|
126
|
-
{/if}
|
|
127
|
-
</article>
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
/**
|
|
3
|
+
* Card component with a title and content.
|
|
4
|
+
* @component
|
|
5
|
+
*/
|
|
6
|
+
import { InformationCircleIcon, UserIcon } from "@hugeicons/core-free-icons";
|
|
7
|
+
import { t } from "../../../../../../i18n";
|
|
8
|
+
import type { CardMediaProps } from "../../types";
|
|
9
|
+
import CardStarRating from "../../shared/CardStarRating.svelte";
|
|
10
|
+
import CardTags from "../../shared/CardTags.svelte";
|
|
11
|
+
import CardDescription from "../../shared/CardDescription.svelte";
|
|
12
|
+
import CardThumbnailVideo from "../../shared/CardThumbnailVideo.svelte";
|
|
13
|
+
import CardButton from "../../shared/CardButton.svelte";
|
|
14
|
+
import CardFavorite from "../../shared/CardFavorite.svelte";
|
|
15
|
+
import Skeleton from "../../../../skeleton/skeleton.svelte";
|
|
16
|
+
import CardLogo from "../../shared/CardLogo.svelte";
|
|
17
|
+
let {
|
|
18
|
+
id,
|
|
19
|
+
tags,
|
|
20
|
+
logo,
|
|
21
|
+
title,
|
|
22
|
+
content,
|
|
23
|
+
className,
|
|
24
|
+
imageUrl,
|
|
25
|
+
videoUrl,
|
|
26
|
+
startNumber,
|
|
27
|
+
startMax = 5,
|
|
28
|
+
isImageButtonMaximized = false,
|
|
29
|
+
isVideoButtonMaximized = false,
|
|
30
|
+
isTagBorderBottom = false,
|
|
31
|
+
isFavorite = false,
|
|
32
|
+
isLoading = false,
|
|
33
|
+
buttonProfileClass,
|
|
34
|
+
buttonDetailsClass,
|
|
35
|
+
isDescriptionIcon,
|
|
36
|
+
isDescriptionLabel,
|
|
37
|
+
onFavoriteClick,
|
|
38
|
+
onButtonProfile,
|
|
39
|
+
onButtonDetails,
|
|
40
|
+
}: CardMediaProps = $props();
|
|
41
|
+
|
|
42
|
+
let isShowButtonProfileAndDetails = $derived(
|
|
43
|
+
onButtonProfile != null && onButtonDetails != null,
|
|
44
|
+
);
|
|
45
|
+
</script>
|
|
46
|
+
|
|
47
|
+
<article
|
|
48
|
+
class="border border-gray-300 dark:border-gray-700 bg-gray-100 dark:bg-transparent rounded-lg p-5 space-y-1 md:space-y-3 {className}"
|
|
49
|
+
>
|
|
50
|
+
<div class="flex flex-col justify-center items-center w-full relative">
|
|
51
|
+
<div class="flex flex-col justify-start gap-2">
|
|
52
|
+
<div class="flex justify-center items-center">
|
|
53
|
+
<CardLogo {logo} {isLoading} />
|
|
54
|
+
</div>
|
|
55
|
+
<div class="flex flex-col justify-center items-center">
|
|
56
|
+
{#if title}
|
|
57
|
+
<div class="text-center font-bold text-lg">{title}</div>
|
|
58
|
+
{:else if isLoading}
|
|
59
|
+
<Skeleton class="w-40 h-5 rounded-lg bg-gray-400 mb-0.5" />
|
|
60
|
+
{/if}
|
|
61
|
+
|
|
62
|
+
{#if startNumber}
|
|
63
|
+
<CardStarRating {startNumber} {startMax} {isLoading} />
|
|
64
|
+
{:else if isLoading}
|
|
65
|
+
<Skeleton class="w-20 h-4 rounded-lg bg-gray-300 mt-0.5" />
|
|
66
|
+
{/if}
|
|
67
|
+
</div>
|
|
68
|
+
</div>
|
|
69
|
+
<div class="flex justify-end items-center absolute top-0 right-0">
|
|
70
|
+
<CardFavorite
|
|
71
|
+
{id}
|
|
72
|
+
{isFavorite}
|
|
73
|
+
onFavoriteClick={() => onFavoriteClick!(id)}
|
|
74
|
+
{isLoading}
|
|
75
|
+
/>
|
|
76
|
+
</div>
|
|
77
|
+
<CardTags tags={tags ?? []} {isTagBorderBottom} {isLoading} />
|
|
78
|
+
</div>
|
|
79
|
+
|
|
80
|
+
<div class="h-24">
|
|
81
|
+
<CardDescription
|
|
82
|
+
{content}
|
|
83
|
+
{isLoading}
|
|
84
|
+
{isDescriptionIcon}
|
|
85
|
+
{isDescriptionLabel}
|
|
86
|
+
/>
|
|
87
|
+
</div>
|
|
88
|
+
|
|
89
|
+
<CardThumbnailVideo
|
|
90
|
+
{imageUrl}
|
|
91
|
+
{videoUrl}
|
|
92
|
+
{isImageButtonMaximized}
|
|
93
|
+
{isVideoButtonMaximized}
|
|
94
|
+
{isLoading}
|
|
95
|
+
/>
|
|
96
|
+
|
|
97
|
+
{#if onButtonProfile || onButtonDetails}
|
|
98
|
+
<div class="flex justify-center items-center gap-2 mt-4 w-full">
|
|
99
|
+
{#if onButtonProfile}
|
|
100
|
+
<CardButton
|
|
101
|
+
{id}
|
|
102
|
+
icon={UserIcon}
|
|
103
|
+
className={buttonProfileClass}
|
|
104
|
+
text={$t("label.view.profile")}
|
|
105
|
+
onClick={onButtonProfile}
|
|
106
|
+
isFlex={isShowButtonProfileAndDetails}
|
|
107
|
+
{isLoading}
|
|
108
|
+
/>
|
|
109
|
+
{:else if isLoading}
|
|
110
|
+
<Skeleton class="w-20 h-4 rounded-lg bg-gray-400 mt-0.5" />
|
|
111
|
+
{/if}
|
|
112
|
+
{#if onButtonDetails}
|
|
113
|
+
<CardButton
|
|
114
|
+
{id}
|
|
115
|
+
icon={InformationCircleIcon}
|
|
116
|
+
className={buttonDetailsClass}
|
|
117
|
+
text={$t("label.more.details")}
|
|
118
|
+
onClick={onButtonDetails}
|
|
119
|
+
isFlex={isShowButtonProfileAndDetails}
|
|
120
|
+
{isLoading}
|
|
121
|
+
/>
|
|
122
|
+
{:else if isLoading}
|
|
123
|
+
<Skeleton class="w-20 h-4 rounded-lg bg-gray-400 mt-0.5" />
|
|
124
|
+
{/if}
|
|
125
|
+
</div>
|
|
126
|
+
{/if}
|
|
127
|
+
</article>
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
import type { CardMediaProps } from "../types";
|
|
3
|
-
import CardMedia01 from "./01/CardMedia01.svelte";
|
|
4
|
-
import CardMedia02 from "./02/CardMedia02.svelte";
|
|
5
|
-
|
|
6
|
-
type Props = {
|
|
7
|
-
variant?: 1 | 2;
|
|
8
|
-
isLoading?: boolean;
|
|
9
|
-
};
|
|
10
|
-
|
|
11
|
-
let { variant, isLoading, ...restProps }: CardMediaProps & Props = $props();
|
|
12
|
-
</script>
|
|
13
|
-
|
|
14
|
-
{#if variant === 2}
|
|
15
|
-
<CardMedia02 {...restProps} {isLoading} />
|
|
16
|
-
{:else}
|
|
17
|
-
<CardMedia01 {...restProps} {isLoading} />
|
|
18
|
-
{/if}
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { CardMediaProps } from "../types";
|
|
3
|
+
import CardMedia01 from "./01/CardMedia01.svelte";
|
|
4
|
+
import CardMedia02 from "./02/CardMedia02.svelte";
|
|
5
|
+
|
|
6
|
+
type Props = {
|
|
7
|
+
variant?: 1 | 2;
|
|
8
|
+
isLoading?: boolean;
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
let { variant, isLoading, ...restProps }: CardMediaProps & Props = $props();
|
|
12
|
+
</script>
|
|
13
|
+
|
|
14
|
+
{#if variant === 2}
|
|
15
|
+
<CardMedia02 {...restProps} {isLoading} />
|
|
16
|
+
{:else}
|
|
17
|
+
<CardMedia01 {...restProps} {isLoading} />
|
|
18
|
+
{/if}
|
|
@@ -1,136 +1,136 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
import Button from "../../../../button/button.svelte";
|
|
3
|
-
import Skeleton from "../../../../skeleton/skeleton.svelte";
|
|
4
|
-
import { t } from "../../../../../../i18n";
|
|
5
|
-
import ImgPlaceHolderGallery from "../../../../../../assets/placeholder-image.png";
|
|
6
|
-
import ImgPlaceholderCompany from "../../../../../../assets/placeholder-company.png";
|
|
7
|
-
import type { CardProductProps } from "../../types";
|
|
8
|
-
import CardFavorite from "../../shared/CardFavorite.svelte";
|
|
9
|
-
import CardCart from "../../shared/CardCart.svelte";
|
|
10
|
-
import CardDescription from "../../shared/CardDescription.svelte";
|
|
11
|
-
import CardTags from "../../shared/CardTags.svelte";
|
|
12
|
-
import CardTitlePrice from "../../shared/CardTitlePrice.svelte";
|
|
13
|
-
|
|
14
|
-
/**
|
|
15
|
-
* Card component with a title and content.
|
|
16
|
-
* @component
|
|
17
|
-
*/
|
|
18
|
-
|
|
19
|
-
let {
|
|
20
|
-
id,
|
|
21
|
-
tags,
|
|
22
|
-
logo,
|
|
23
|
-
title,
|
|
24
|
-
imageUrl,
|
|
25
|
-
rating = 0,
|
|
26
|
-
isFavorite = false,
|
|
27
|
-
isCart = false,
|
|
28
|
-
isLoading = false,
|
|
29
|
-
content,
|
|
30
|
-
price,
|
|
31
|
-
buttonBuyText,
|
|
32
|
-
buttonBuyClass,
|
|
33
|
-
isDescriptionIcon,
|
|
34
|
-
isDescriptionLabel,
|
|
35
|
-
onClickBuy,
|
|
36
|
-
onClickShop,
|
|
37
|
-
onClickFavorite,
|
|
38
|
-
}: CardProductProps = $props();
|
|
39
|
-
</script>
|
|
40
|
-
|
|
41
|
-
<article class="relative rounded-lg border">
|
|
42
|
-
<aside class="relative w-full p-2">
|
|
43
|
-
<div class="absolute top-2 left-2 z-2 gap-1 p-2">
|
|
44
|
-
{#if isLoading}
|
|
45
|
-
<Skeleton class="h-5 w-20 rounded-full bg-black/20" />
|
|
46
|
-
{:else if logo}
|
|
47
|
-
<img
|
|
48
|
-
src={logo}
|
|
49
|
-
width={30}
|
|
50
|
-
height={30}
|
|
51
|
-
alt={title}
|
|
52
|
-
onerror={(e) =>
|
|
53
|
-
((e.target as HTMLImageElement).src = ImgPlaceholderCompany)}
|
|
54
|
-
class="rounded-lg"
|
|
55
|
-
/>
|
|
56
|
-
{:else}
|
|
57
|
-
<img
|
|
58
|
-
src={ImgPlaceholderCompany}
|
|
59
|
-
width={30}
|
|
60
|
-
height={30}
|
|
61
|
-
alt={title}
|
|
62
|
-
class="rounded-lg"
|
|
63
|
-
/>
|
|
64
|
-
{/if}
|
|
65
|
-
</div>
|
|
66
|
-
|
|
67
|
-
<div class="absolute top-2 right-2 z-2 flex items-center gap-1 p-2">
|
|
68
|
-
<CardFavorite
|
|
69
|
-
{id}
|
|
70
|
-
{isFavorite}
|
|
71
|
-
{isLoading}
|
|
72
|
-
onFavoriteClick={onClickFavorite}
|
|
73
|
-
/>
|
|
74
|
-
<CardCart {id} {isCart} {isLoading} onCartClick={onClickShop} />
|
|
75
|
-
</div>
|
|
76
|
-
|
|
77
|
-
{#if isLoading}
|
|
78
|
-
<Skeleton
|
|
79
|
-
class="rounded-lg h-30 w-full object-cover object-center bg-black/15"
|
|
80
|
-
/>
|
|
81
|
-
{:else if imageUrl}
|
|
82
|
-
<img
|
|
83
|
-
src={imageUrl}
|
|
84
|
-
alt={imageUrl}
|
|
85
|
-
class="rounded-lg h-36 md:h-44 w-full object-cover object-center"
|
|
86
|
-
onerror={(e) =>
|
|
87
|
-
((e.target as HTMLImageElement).src = ImgPlaceHolderGallery)}
|
|
88
|
-
/>
|
|
89
|
-
{:else}
|
|
90
|
-
<img
|
|
91
|
-
src={ImgPlaceHolderGallery}
|
|
92
|
-
alt="Not Found"
|
|
93
|
-
class="rounded-lg h-36 md:h-44 w-full object-cover object-center"
|
|
94
|
-
/>
|
|
95
|
-
{/if}
|
|
96
|
-
<div class="absolute inset-0 bg-black/5 rounded-sm h-full w-full"></div>
|
|
97
|
-
</aside>
|
|
98
|
-
|
|
99
|
-
<aside
|
|
100
|
-
class="bottom-1 inset-x-0 flex flex-col items-center justify-center gap-0.5 m-auto max-w-11/12 p-1 rounded-md"
|
|
101
|
-
>
|
|
102
|
-
<div class="flex justify-between w-full items-center mb-1">
|
|
103
|
-
{#if title}
|
|
104
|
-
{#if isLoading}
|
|
105
|
-
<Skeleton class="h-4 w-30 rounded-lg" />
|
|
106
|
-
{:else}
|
|
107
|
-
<div class="font-semibold line-clamp-1 flex-nowrap">
|
|
108
|
-
{title}
|
|
109
|
-
</div>
|
|
110
|
-
{/if}
|
|
111
|
-
{/if}
|
|
112
|
-
<CardTitlePrice {title} {isLoading} {price} />
|
|
113
|
-
</div>
|
|
114
|
-
|
|
115
|
-
{#if tags && tags.length > 0}
|
|
116
|
-
<div class="w-full my-1">
|
|
117
|
-
<CardTags {tags} />
|
|
118
|
-
</div>
|
|
119
|
-
{/if}
|
|
120
|
-
|
|
121
|
-
<div>
|
|
122
|
-
<CardDescription {content} {isDescriptionIcon} {isDescriptionLabel} />
|
|
123
|
-
</div>
|
|
124
|
-
|
|
125
|
-
{#if isLoading}
|
|
126
|
-
<Skeleton class="h-9 w-full rounded-md" />
|
|
127
|
-
{:else}
|
|
128
|
-
<Button
|
|
129
|
-
onclick={() => onClickBuy!(id)}
|
|
130
|
-
class="w-full mb-2 bg-gradient text-white rounded-full {buttonBuyClass}"
|
|
131
|
-
>
|
|
132
|
-
{buttonBuyText || $t("label.buy")}
|
|
133
|
-
</Button>
|
|
134
|
-
{/if}
|
|
135
|
-
</aside>
|
|
136
|
-
</article>
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import Button from "../../../../button/button.svelte";
|
|
3
|
+
import Skeleton from "../../../../skeleton/skeleton.svelte";
|
|
4
|
+
import { t } from "../../../../../../i18n";
|
|
5
|
+
import ImgPlaceHolderGallery from "../../../../../../assets/placeholder-image.png";
|
|
6
|
+
import ImgPlaceholderCompany from "../../../../../../assets/placeholder-company.png";
|
|
7
|
+
import type { CardProductProps } from "../../types";
|
|
8
|
+
import CardFavorite from "../../shared/CardFavorite.svelte";
|
|
9
|
+
import CardCart from "../../shared/CardCart.svelte";
|
|
10
|
+
import CardDescription from "../../shared/CardDescription.svelte";
|
|
11
|
+
import CardTags from "../../shared/CardTags.svelte";
|
|
12
|
+
import CardTitlePrice from "../../shared/CardTitlePrice.svelte";
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* Card component with a title and content.
|
|
16
|
+
* @component
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
let {
|
|
20
|
+
id,
|
|
21
|
+
tags,
|
|
22
|
+
logo,
|
|
23
|
+
title,
|
|
24
|
+
imageUrl,
|
|
25
|
+
rating = 0,
|
|
26
|
+
isFavorite = false,
|
|
27
|
+
isCart = false,
|
|
28
|
+
isLoading = false,
|
|
29
|
+
content,
|
|
30
|
+
price,
|
|
31
|
+
buttonBuyText,
|
|
32
|
+
buttonBuyClass,
|
|
33
|
+
isDescriptionIcon,
|
|
34
|
+
isDescriptionLabel,
|
|
35
|
+
onClickBuy,
|
|
36
|
+
onClickShop,
|
|
37
|
+
onClickFavorite,
|
|
38
|
+
}: CardProductProps = $props();
|
|
39
|
+
</script>
|
|
40
|
+
|
|
41
|
+
<article class="relative rounded-lg border">
|
|
42
|
+
<aside class="relative w-full p-2">
|
|
43
|
+
<div class="absolute top-2 left-2 z-2 gap-1 p-2">
|
|
44
|
+
{#if isLoading}
|
|
45
|
+
<Skeleton class="h-5 w-20 rounded-full bg-black/20" />
|
|
46
|
+
{:else if logo}
|
|
47
|
+
<img
|
|
48
|
+
src={logo}
|
|
49
|
+
width={30}
|
|
50
|
+
height={30}
|
|
51
|
+
alt={title}
|
|
52
|
+
onerror={(e) =>
|
|
53
|
+
((e.target as HTMLImageElement).src = ImgPlaceholderCompany)}
|
|
54
|
+
class="rounded-lg"
|
|
55
|
+
/>
|
|
56
|
+
{:else}
|
|
57
|
+
<img
|
|
58
|
+
src={ImgPlaceholderCompany}
|
|
59
|
+
width={30}
|
|
60
|
+
height={30}
|
|
61
|
+
alt={title}
|
|
62
|
+
class="rounded-lg"
|
|
63
|
+
/>
|
|
64
|
+
{/if}
|
|
65
|
+
</div>
|
|
66
|
+
|
|
67
|
+
<div class="absolute top-2 right-2 z-2 flex items-center gap-1 p-2">
|
|
68
|
+
<CardFavorite
|
|
69
|
+
{id}
|
|
70
|
+
{isFavorite}
|
|
71
|
+
{isLoading}
|
|
72
|
+
onFavoriteClick={onClickFavorite}
|
|
73
|
+
/>
|
|
74
|
+
<CardCart {id} {isCart} {isLoading} onCartClick={onClickShop} />
|
|
75
|
+
</div>
|
|
76
|
+
|
|
77
|
+
{#if isLoading}
|
|
78
|
+
<Skeleton
|
|
79
|
+
class="rounded-lg h-30 w-full object-cover object-center bg-black/15"
|
|
80
|
+
/>
|
|
81
|
+
{:else if imageUrl}
|
|
82
|
+
<img
|
|
83
|
+
src={imageUrl}
|
|
84
|
+
alt={imageUrl}
|
|
85
|
+
class="rounded-lg h-36 md:h-44 w-full object-cover object-center"
|
|
86
|
+
onerror={(e) =>
|
|
87
|
+
((e.target as HTMLImageElement).src = ImgPlaceHolderGallery)}
|
|
88
|
+
/>
|
|
89
|
+
{:else}
|
|
90
|
+
<img
|
|
91
|
+
src={ImgPlaceHolderGallery}
|
|
92
|
+
alt="Not Found"
|
|
93
|
+
class="rounded-lg h-36 md:h-44 w-full object-cover object-center"
|
|
94
|
+
/>
|
|
95
|
+
{/if}
|
|
96
|
+
<div class="absolute inset-0 bg-black/5 rounded-sm h-full w-full"></div>
|
|
97
|
+
</aside>
|
|
98
|
+
|
|
99
|
+
<aside
|
|
100
|
+
class="bottom-1 inset-x-0 flex flex-col items-center justify-center gap-0.5 m-auto max-w-11/12 p-1 rounded-md"
|
|
101
|
+
>
|
|
102
|
+
<div class="flex justify-between w-full items-center mb-1">
|
|
103
|
+
{#if title}
|
|
104
|
+
{#if isLoading}
|
|
105
|
+
<Skeleton class="h-4 w-30 rounded-lg" />
|
|
106
|
+
{:else}
|
|
107
|
+
<div class="font-semibold line-clamp-1 flex-nowrap">
|
|
108
|
+
{title}
|
|
109
|
+
</div>
|
|
110
|
+
{/if}
|
|
111
|
+
{/if}
|
|
112
|
+
<CardTitlePrice {title} {isLoading} {price} />
|
|
113
|
+
</div>
|
|
114
|
+
|
|
115
|
+
{#if tags && tags.length > 0}
|
|
116
|
+
<div class="w-full my-1">
|
|
117
|
+
<CardTags {tags} />
|
|
118
|
+
</div>
|
|
119
|
+
{/if}
|
|
120
|
+
|
|
121
|
+
<div>
|
|
122
|
+
<CardDescription {content} {isDescriptionIcon} {isDescriptionLabel} />
|
|
123
|
+
</div>
|
|
124
|
+
|
|
125
|
+
{#if isLoading}
|
|
126
|
+
<Skeleton class="h-9 w-full rounded-md" />
|
|
127
|
+
{:else}
|
|
128
|
+
<Button
|
|
129
|
+
onclick={() => onClickBuy!(id)}
|
|
130
|
+
class="w-full mb-2 bg-gradient text-white rounded-full {buttonBuyClass}"
|
|
131
|
+
>
|
|
132
|
+
{buttonBuyText || $t("label.buy")}
|
|
133
|
+
</Button>
|
|
134
|
+
{/if}
|
|
135
|
+
</aside>
|
|
136
|
+
</article>
|