@trafilea/afrodita-components 7.14.3 → 7.14.5

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.
@@ -1,2 +1,2 @@
1
- import{__assign as o}from"tslib";import{jsxs as i,Fragment as t,jsx as d}from"react/jsx-runtime";import{useZoom as e}from"../../../organisms/ModalZoom/useZoom.js";import{ZoomButtonComponent as l}from"../../../organisms/ModalZoom/ZoomButton.js";import{Video as r}from"../../../molecules/Video/Video.js";import{Container as a,InnerImageZoomStyled as n,ImageStyled as s,TopTagContainer as m,BottomTagContainer as v,TopRightTagWrapper as c,TopRightTagContainer as u,ButtonSecondaryOutlineWrapper as h}from"./styled.js";var p=function(p){var g,b=p.content,z=p.topTag,y=p.topRightTag,f=p.bottomTag,j=p.testId,V=p.position,M=void 0===V?"vertical":V,R=p.borderRadiusVariant,T=p.ctaText,w=p.ctaAction,x=p.hideCTA,C=p.withZoom,I=p.isRatioSquare,Z=p.videoAutoplay,A=void 0!==Z&&Z,k=p.hideVideoControls,S=void 0!==k&&k,q=p.zoomOptions,B=null==b?void 0:b.url,P=null!==(g=null==b?void 0:b.isVideo)&&void 0!==g&&g,F=A||null==b?void 0:b.thumbnailUrl,H=S?{pointerEvents:"none"}:void 0,O=e((null==q?void 0:q.zoomModalId)||"zoom-modal-v1").handleZoomClick;return i(a,o({"data-testid":j,className:"stylefor".concat(M),borderRadiusVariant:R,position:M,onClick:(null==q?void 0:q.zoomModalId)?O:void 0},{children:[!P&&i(t,{children:[C?d(n,{src:B,zoomSrc:B,zoomType:"hover",imgAttributes:{alt:b.alt,style:{objectFit:"cover",objectPosition:"center"},loading:"eager",decoding:"sync"},width:"horizontal"==M?360:530,height:"horizontal"==M?480:720,hideHint:!0,isRatioSquare:I},void 0):d(s,{width:"horizontal"==M?"360px":"530px",height:"auto",src:B,alt:b.alt,objectFit:"cover",loading:"eager",decoding:"sync",isRatioSquare:I},void 0),d(m,o({borderRadiusVariant:R},{children:z}),void 0),d(v,o({isCTAHidden:x},{children:f}),void 0),!!y&&d(c,{children:d(u,{children:y},void 0)},void 0)]},void 0),P&&d(r,{source:B,thumbnail:F,autoPlay:A,muted:!0,loop:!0,withProgressBar:!S,style:H,preload:"auto"},void 0),T&&w&&d("div",o({style:{display:x?"none":"block"}},{children:d(h,{wide:!0,onClick:w,text:T},void 0)}),void 0),Boolean(null==q?void 0:q.zoomModalId)&&d(l,{modalId:(null==q?void 0:q.zoomModalId)||"zoom-modal-v1",showOnMobile:"v2"===(null==q?void 0:q.zoomVersion)},void 0)]}),void 0)};export{p as ImageProductSlide};
1
+ import{__assign as o}from"tslib";import{jsxs as i,Fragment as d,jsx as t}from"react/jsx-runtime";import{useZoom as e}from"../../../organisms/ModalZoom/useZoom.js";import{ZoomButtonComponent as l}from"../../../organisms/ModalZoom/ZoomButton.js";import{Video as r}from"../../../molecules/Video/Video.js";import{Container as a,InnerImageZoomStyled as n,ImageStyled as s,TopTagContainer as m,BottomTagContainer as v,TopRightTagWrapper as c,TopRightTagContainer as u,ButtonSecondaryOutlineWrapper as h}from"./styled.js";var p=function(p){var g,z=p.content,b=p.topTag,y=p.topRightTag,f=p.bottomTag,j=p.testId,I=p.position,M=void 0===I?"vertical":I,V=p.borderRadiusVariant,R=p.ctaText,T=p.ctaAction,Z=p.hideCTA,w=p.withZoom,x=p.isRatioSquare,A=p.videoAutoplay,C=void 0!==A&&A,k=p.hideVideoControls,S=void 0!==k&&k,q=p.zoomOptions,B=null==z?void 0:z.url,P=null!==(g=null==z?void 0:z.isVideo)&&void 0!==g&&g,F=C||null==z?void 0:z.thumbnailUrl,H=S?{pointerEvents:"none"}:void 0,O=e((null==q?void 0:q.zoomModalId)||"zoom-modal-v1").handleZoomClick;return i(a,o({"data-testid":j,className:"stylefor".concat(M),borderRadiusVariant:V,position:M},{children:[!P&&i(d,{children:[w?t(n,{src:B,zoomSrc:B,zoomType:(null==q?void 0:q.zoomModalId)?"click":"hover",imgAttributes:{alt:z.alt,style:{objectFit:"cover",objectPosition:"center"},loading:"eager",decoding:"sync"},width:"horizontal"==M?360:530,height:"horizontal"==M?480:720,hideHint:!0,isRatioSquare:x,afterZoomIn:(null==q?void 0:q.zoomModalId)?O:void 0},void 0):t(s,{width:"horizontal"==M?"360px":"530px",height:"auto",src:B,alt:z.alt,objectFit:"cover",loading:"eager",decoding:"sync",isRatioSquare:x},void 0),t(m,o({borderRadiusVariant:V},{children:b}),void 0),t(v,o({isCTAHidden:Z},{children:f}),void 0),!!y&&t(c,{children:t(u,{children:y},void 0)},void 0)]},void 0),P&&t(r,{source:B,thumbnail:F,autoPlay:C,muted:!0,loop:!0,withProgressBar:!S,style:H,preload:"auto"},void 0),R&&T&&t("div",o({style:{display:Z?"none":"block"}},{children:t(h,{wide:!0,onClick:T,text:R},void 0)}),void 0),Boolean(null==q?void 0:q.zoomModalId)&&t(l,{modalId:(null==q?void 0:q.zoomModalId)||"zoom-modal-v1",showOnMobile:"v2"===(null==q?void 0:q.zoomVersion)},void 0)]}),void 0)};export{p as ImageProductSlide};
2
2
  //# sourceMappingURL=ImageProductSlide.js.map
package/build/index.d.ts CHANGED
@@ -207,11 +207,11 @@ declare type Custom$1 = 'custom/atom' | 'custom/avatar_placeholder' | 'custom/br
207
207
  declare type Download$1 = 'download/apple_store' | 'download/google_play';
208
208
  declare type Emoji$1 = 'emoji/blowing_kiss' | 'emoji/frowning' | 'emoji/grinning' | 'emoji/grinning_with_sweat' | 'emoji/relieved' | 'emoji/smiling_v2' | 'emoji/smiling_v3' | 'emoji/thinking';
209
209
  declare type Messaging$1 = 'messaging/ada_chat' | 'messaging/comment' | 'messaging/comment_dots' | 'messaging/comment_light' | 'messaging/comment_money' | 'messaging/community' | 'messaging/light' | 'messaging/light_bulb' | 'messaging/light_bulb_solid' | 'messaging/mail' | 'messaging/mail_sent' | 'messaging/messenger' | 'messaging/question_circle' | 'messaging/quote_left' | 'messaging/quote_right' | 'messaging/quote_solid_left' | 'messaging/quote_solid_right' | 'messaging/question_circle_light';
210
- declare type MyAccount$1 = 'myaccount/birthday_gifts' | 'myaccount/community' | 'myaccount/deals_offers' | 'myaccount/free_returns' | 'myaccount/free_shipping' | 'myaccount/guard' | 'myaccount/members_only_discount' | 'myaccount/members_only_discount_opposite' | 'myaccount/personal_stylist' | 'myaccount/priority_shipping' | 'myaccount/profile' | 'myaccount/place_image' | 'myaccount/sale_tag' | 'myaccount/style_fashion_content' | 'myaccount/cart' | 'myaccount/vip' | 'myaccount/calendar' | 'myaccount/skin_type' | 'myaccount/magnify' | 'myaccount/beauty_products' | 'myaccount/email' | 'myaccount/contact' | 'myaccount/frowing' | 'myaccount/wallet_thin' | 'myaccount/box' | 'myaccount/cursor_click';
210
+ declare type MyAccount$1 = 'myaccount/birthday_gifts' | 'myaccount/community' | 'myaccount/deals_offers' | 'myaccount/free_returns' | 'myaccount/free_shipping' | 'myaccount/guard' | 'myaccount/members_only_discount' | 'myaccount/members_only_discount_opposite' | 'myaccount/personal_stylist' | 'myaccount/priority_shipping' | 'myaccount/profile' | 'myaccount/place_image' | 'myaccount/sale_tag' | 'myaccount/style_fashion_content' | 'myaccount/cart' | 'myaccount/vip' | 'myaccount/calendar' | 'myaccount/skin_type' | 'myaccount/magnify' | 'myaccount/beauty_products' | 'myaccount/email' | 'myaccount/contact' | 'myaccount/frowing' | 'myaccount/wallet_thin' | 'myaccount/box' | 'myaccount/cursor_click' | 'myaccount/fluent_tag' | 'myaccount/hands_dolar' | 'myaccount/comment_money' | 'myaccount/shop_cart' | 'myaccount/club_evolution_1' | 'myaccount/club_evolution_2' | 'myaccount/club_evolution_3';
211
211
  declare type Navigation$1 = 'navigation/address_information' | 'navigation/benefits' | 'navigation/benefits_v2' | 'navigation/club_membership' | 'navigation/ellipsis' | 'navigation/ellipsis_horizontal' | 'navigation/filters' | 'navigation/hamburger' | 'navigation/home' | 'navigation/home_solid' | 'navigation/loading' | 'navigation/lock' | 'navigation/lock_solid' | 'navigation/map_marker' | 'navigation/map_marker_light' | 'navigation/map_solid' | 'navigation/menu_lines' | 'navigation/search' | 'navigation/shaperbox' | 'navigation/shopping_bag' | 'navigation/shopping_bag_v2' | 'navigation/shopping_bag_v3' | 'navigation/shopping_bag_v4' | 'navigation/shopping_cart' | 'navigation/shopping_cart_v2' | 'navigation/slide_dot' | 'navigation/slide_dot_solid' | 'navigation/user' | 'navigation/address_information_light' | 'navigation/user_solid' | 'navigation/user_v2' | 'navigation/filters_v2' | 'navigation/gift';
212
212
  declare type Other$1 = 'other/alarm_on' | 'other/bod_con_label' | 'other/bod_con_mobile_label' | 'other/call_us' | 'other/chat' | 'other/email' | 'other/express_shipping' | 'other/fit_guarantee' | 'other/fit_predictor' | 'other/free_exchange' | 'other/get_discount' | 'other/hassel_free_returns' | 'other/loading' | 'other/mc_afee' | 'other/megafone' | 'other/play' | 'other/qr_code' | 'other/question_with_circle' | 'other/revel_beauty' | 'other/shapermint' | 'other/shapermint_club_icon' | 'other/shapermint_club_icon2' | 'other/shapermint_club_label' | 'other/shapermint_club_mobile_label' | 'other/shapermint_logo' | 'other/shm_club' | 'other/shop_now' | 'other/sign_form' | 'other/sixty_days_tsd' | 'other/the_bod_con' | 'other/the_spa_dr' | 'other/lock' | 'other/help_center' | 'other/arrow_outward' | 'other/coupons' | 'other/flag_usa' | 'other/flag_canada' | 'other/flag_aus' | 'other/flag_uk' | 'other/flag_nz' | 'other/flag_sg' | 'other/bookmark' | 'other/stars' | 'other/club_filled';
213
213
  declare type Payment$1 = 'payment/amazon' | 'payment/amex' | 'payment/jcb' | 'payment/klarna' | 'payment/master_card' | 'payment/paypal' | 'payment/visa' | 'payment/payment_methods';
214
- declare type PDP$1 = 'pdp/circle_number' | 'pdp/ai_magic' | 'pdp/clock' | 'pdp/drop' | 'pdp/drop_empty' | 'pdp/error_cross' | 'pdp/flag_usa' | 'pdp/hours' | 'pdp/klarna_logo' | 'pdp/light_bulb' | 'pdp/free_returns_v2' | 'pdp/free_shipping_v2' | 'pdp/loading_trafisizy' | 'pdp/minus' | 'pdp/moon' | 'pdp/tape_measure' | 'pdp/new_clock' | 'pdp/play_mini' | 'pdp/play_video' | 'pdp/plus' | 'pdp/rule' | 'pdp/shipping' | 'pdp/shipping_empty' | 'pdp/size_empty' | 'pdp/size_empty_v2' | 'pdp/size_with_stars' | 'pdp/star' | 'pdp/stars' | 'pdp/star_empty' | 'pdp/star_half' | 'pdp/stopwatch' | 'pdp/drop_v2' | 'pdp/few_drops' | 'pdp/trust_badge' | 'pdp/verified' | 'pdp/wrinkle_free_face' | 'pdp/skin_appearance' | 'pdp/shine_heart' | 'pdp/cruelty_free' | 'pdp/ph_formula' | 'pdp/box' | 'pdp/afterpay_logo' | 'pdp/trustpilot_star' | 'pdp/trustpilot_half_star' | 'pdp/zoom';
214
+ declare type PDP$1 = 'pdp/circle_number' | 'pdp/ai_magic' | 'pdp/clock' | 'pdp/drop' | 'pdp/drop_empty' | 'pdp/error_cross' | 'pdp/flag_usa' | 'pdp/hours' | 'pdp/klarna_logo' | 'pdp/light_bulb' | 'pdp/free_returns_v2' | 'pdp/free_shipping_v2' | 'pdp/loading_trafisizy' | 'pdp/minus' | 'pdp/moon' | 'pdp/tape_measure' | 'pdp/new_clock' | 'pdp/play_mini' | 'pdp/play_video' | 'pdp/plus' | 'pdp/rule' | 'pdp/shipping' | 'pdp/shipping_empty' | 'pdp/size_empty' | 'pdp/size_empty_v2' | 'pdp/size_with_stars' | 'pdp/star' | 'pdp/stars' | 'pdp/star_empty' | 'pdp/star_half' | 'pdp/stopwatch' | 'pdp/drop_v2' | 'pdp/few_drops' | 'pdp/trust_badge' | 'pdp/verified' | 'pdp/wrinkle_free_face' | 'pdp/skin_appearance' | 'pdp/shine_heart' | 'pdp/cruelty_free' | 'pdp/ph_formula' | 'pdp/box' | 'pdp/afterpay_logo' | 'pdp/trustpilot_star' | 'pdp/trustpilot_half_star' | 'pdp/zoom' | 'pdp/club_evolution';
215
215
  declare type SlideDots$1 = 'slidedots/slide_dot';
216
216
  declare type SocialMedia$1 = 'socialmedia/facebook' | 'socialmedia/facebook_solid' | 'socialmedia/instagram' | 'socialmedia/instagram_solid' | 'socialmedia/interaction' | 'socialmedia/pinterest' | 'socialmedia/twitter' | 'socialmedia/youtube' | 'socialmedia/spotify' | 'socialmedia/apple_podcast';
217
217
  declare type IconName = Actions$1 | Arrows$1 | Custom$1 | Download$1 | Emoji$1 | Messaging$1 | MyAccount$1 | Navigation$1 | Other$1 | Payment$1 | PDP$1 | SlideDots$1 | SocialMedia$1;
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var o=require("tslib"),i=require("react/jsx-runtime"),e=require("../../../organisms/ModalZoom/useZoom.js"),t=require("../../../organisms/ModalZoom/ZoomButton.js"),d=require("../../../molecules/Video/Video.js"),a=require("./styled.js");exports.ImageProductSlide=function(n){var r,l=n.content,s=n.topTag,u=n.topRightTag,c=n.bottomTag,v=n.testId,m=n.position,g=void 0===m?"vertical":m,h=n.borderRadiusVariant,p=n.ctaText,j=n.ctaAction,x=n.hideCTA,y=n.withZoom,b=n.isRatioSquare,T=n.videoAutoplay,z=void 0!==T&&T,C=n.hideVideoControls,I=void 0!==C&&C,_=n.zoomOptions,q=null==l?void 0:l.url,R=null!==(r=null==l?void 0:l.isVideo)&&void 0!==r&&r,V=z||null==l?void 0:l.thumbnailUrl,Z=I?{pointerEvents:"none"}:void 0,M=e.useZoom((null==_?void 0:_.zoomModalId)||"zoom-modal-v1").handleZoomClick;return i.jsxs(a.Container,o.__assign({"data-testid":v,className:"stylefor".concat(g),borderRadiusVariant:h,position:g,onClick:(null==_?void 0:_.zoomModalId)?M:void 0},{children:[!R&&i.jsxs(i.Fragment,{children:[y?i.jsx(a.InnerImageZoomStyled,{src:q,zoomSrc:q,zoomType:"hover",imgAttributes:{alt:l.alt,style:{objectFit:"cover",objectPosition:"center"},loading:"eager",decoding:"sync"},width:"horizontal"==g?360:530,height:"horizontal"==g?480:720,hideHint:!0,isRatioSquare:b},void 0):i.jsx(a.ImageStyled,{width:"horizontal"==g?"360px":"530px",height:"auto",src:q,alt:l.alt,objectFit:"cover",loading:"eager",decoding:"sync",isRatioSquare:b},void 0),i.jsx(a.TopTagContainer,o.__assign({borderRadiusVariant:h},{children:s}),void 0),i.jsx(a.BottomTagContainer,o.__assign({isCTAHidden:x},{children:c}),void 0),!!u&&i.jsx(a.TopRightTagWrapper,{children:i.jsx(a.TopRightTagContainer,{children:u},void 0)},void 0)]},void 0),R&&i.jsx(d.Video,{source:q,thumbnail:V,autoPlay:z,muted:!0,loop:!0,withProgressBar:!I,style:Z,preload:"auto"},void 0),p&&j&&i.jsx("div",o.__assign({style:{display:x?"none":"block"}},{children:i.jsx(a.ButtonSecondaryOutlineWrapper,{wide:!0,onClick:j,text:p},void 0)}),void 0),Boolean(null==_?void 0:_.zoomModalId)&&i.jsx(t.ZoomButtonComponent,{modalId:(null==_?void 0:_.zoomModalId)||"zoom-modal-v1",showOnMobile:"v2"===(null==_?void 0:_.zoomVersion)},void 0)]}),void 0)};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var o=require("tslib"),i=require("react/jsx-runtime"),e=require("../../../organisms/ModalZoom/useZoom.js"),t=require("../../../organisms/ModalZoom/ZoomButton.js"),d=require("../../../molecules/Video/Video.js"),a=require("./styled.js");exports.ImageProductSlide=function(n){var r,l=n.content,s=n.topTag,u=n.topRightTag,c=n.bottomTag,m=n.testId,v=n.position,g=void 0===v?"vertical":v,h=n.borderRadiusVariant,p=n.ctaText,j=n.ctaAction,x=n.hideCTA,y=n.withZoom,b=n.isRatioSquare,z=n.videoAutoplay,T=void 0!==z&&z,I=n.hideVideoControls,C=void 0!==I&&I,Z=n.zoomOptions,_=null==l?void 0:l.url,q=null!==(r=null==l?void 0:l.isVideo)&&void 0!==r&&r,M=T||null==l?void 0:l.thumbnailUrl,R=C?{pointerEvents:"none"}:void 0,V=e.useZoom((null==Z?void 0:Z.zoomModalId)||"zoom-modal-v1").handleZoomClick;return i.jsxs(a.Container,o.__assign({"data-testid":m,className:"stylefor".concat(g),borderRadiusVariant:h,position:g},{children:[!q&&i.jsxs(i.Fragment,{children:[y?i.jsx(a.InnerImageZoomStyled,{src:_,zoomSrc:_,zoomType:(null==Z?void 0:Z.zoomModalId)?"click":"hover",imgAttributes:{alt:l.alt,style:{objectFit:"cover",objectPosition:"center"},loading:"eager",decoding:"sync"},width:"horizontal"==g?360:530,height:"horizontal"==g?480:720,hideHint:!0,isRatioSquare:b,afterZoomIn:(null==Z?void 0:Z.zoomModalId)?V:void 0},void 0):i.jsx(a.ImageStyled,{width:"horizontal"==g?"360px":"530px",height:"auto",src:_,alt:l.alt,objectFit:"cover",loading:"eager",decoding:"sync",isRatioSquare:b},void 0),i.jsx(a.TopTagContainer,o.__assign({borderRadiusVariant:h},{children:s}),void 0),i.jsx(a.BottomTagContainer,o.__assign({isCTAHidden:x},{children:c}),void 0),!!u&&i.jsx(a.TopRightTagWrapper,{children:i.jsx(a.TopRightTagContainer,{children:u},void 0)},void 0)]},void 0),q&&i.jsx(d.Video,{source:_,thumbnail:M,autoPlay:T,muted:!0,loop:!0,withProgressBar:!C,style:R,preload:"auto"},void 0),p&&j&&i.jsx("div",o.__assign({style:{display:x?"none":"block"}},{children:i.jsx(a.ButtonSecondaryOutlineWrapper,{wide:!0,onClick:j,text:p},void 0)}),void 0),Boolean(null==Z?void 0:Z.zoomModalId)&&i.jsx(t.ZoomButtonComponent,{modalId:(null==Z?void 0:Z.zoomModalId)||"zoom-modal-v1",showOnMobile:"v2"===(null==Z?void 0:Z.zoomVersion)},void 0)]}),void 0)};
2
2
  //# sourceMappingURL=ImageProductSlide.js.map
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "description": "Trafilea's Design System",
4
4
  "author": "Trafilea",
5
5
  "repository": "https://github.com/trafilea/afrodita-components",
6
- "version": "7.14.3",
6
+ "version": "7.14.5",
7
7
  "private": false,
8
8
  "main": "build/lib/index.js",
9
9
  "style": "build/es/index.css",