@fonixtree/magic-design 2.0.202 → 2.0.203
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/es/assets/fonts/AvenirNext-Bold.ttf +0 -0
- package/es/assets/fonts/AvenirNext-DemiBold.ttf +0 -0
- package/es/assets/fonts/AvenirNext-Medium.ttf +0 -0
- package/es/assets/fonts/AvenirNext-Regular.ttf +0 -0
- package/es/assets/fonts/magic-box-iconfont.css +27 -3
- package/es/assets/fonts/magic-box-iconfont.js +1 -1
- package/es/assets/fonts/magic-box-iconfont.ttf +0 -0
- package/es/assets/fonts/magic-box-iconfont.woff +0 -0
- package/es/assets/fonts/magic-box-iconfont.woff2 +0 -0
- package/es/assets/images/layout-icon/banner-slide-layout3.png +0 -0
- package/es/assets/images/layout-icon/grouped-carousel-layout1.png +0 -0
- package/es/assets/images/layout-icon/news-layout1.png +0 -0
- package/es/assets/images/layout-icon/search-dito-layout1.png +0 -0
- package/es/assets/images/layout-icon/slide-image-layout1.png +0 -0
- package/es/assets/less/font.less +30 -0
- package/es/assets/less/global.less +5 -0
- package/es/common/CountDown/index.js +29 -2
- package/es/common/CountDown/index.less +38 -5
- package/es/common/LinkModal/ProductList/index.js +484 -0
- package/es/common/LinkModal/ProductList/index.less +130 -0
- package/es/common/LinkModal/index.js +8 -1
- package/es/common/ProductCardModal/imgs/dot-icon.png +0 -0
- package/es/common/ProductCardModal/index.js +255 -0
- package/es/common/ProductCardModal/index.less +131 -0
- package/es/common/Toast/index.js +30 -0
- package/es/common/Toast/index.less +29 -0
- package/es/common/UrlPicker/index.js +1 -1
- package/es/common/Video/index.js +5 -3
- package/es/common/VideoPC/background.png +0 -0
- package/es/common/VideoPC/closeImg.png +0 -0
- package/es/common/VideoPC/components/index.js +100 -0
- package/es/common/VideoPC/components/index.less +62 -0
- package/es/common/VideoPC/cover.png +0 -0
- package/es/common/VideoPC/index.js +750 -0
- package/es/common/VideoPC/index.less +79 -0
- package/es/common/index.js +24 -0
- package/es/composite-comp/common/components/ProductItem/index.js +15 -8
- package/es/composite-comp/common/components/ProductItem/index.less +7 -0
- package/es/composite-comp/common/config-panels/BackgroundConfig/index.js +15 -73
- package/es/composite-comp/common/config-panels/SpacingConfig/index.js +30 -0
- package/es/composite-comp/dito/components/CommonFunctions/defaultJSON.js +1 -1
- package/es/composite-comp/dito/components/CommonFunctions/mobile/index.js +8 -0
- package/es/composite-comp/dito/components/CommonFunctions/mobile/index.less +3 -0
- package/es/composite-comp/dito/components/FlashDeal/defaultJSON.js +26 -12
- package/es/composite-comp/dito/components/FlashDeal/mobile/index.js +15 -14
- package/es/composite-comp/dito/components/FlashDeal/pc/ProductItem/index.js +197 -0
- package/es/composite-comp/dito/components/FlashDeal/pc/ProductItem/index.less +100 -0
- package/es/composite-comp/dito/components/FlashDeal/pc/index.js +18 -22
- package/es/composite-comp/dito/components/FlashDeal/pc/index.less +19 -30
- package/es/composite-comp/dito/components/GroupBuy/mobile/index.less +5 -2
- package/es/composite-comp/dito/components/GroupedCarousel/defaultJSON.js +312 -0
- package/es/composite-comp/dito/components/GroupedCarousel/index.js +86 -0
- package/es/composite-comp/dito/components/GroupedCarousel/pc/index.js +189 -0
- package/es/composite-comp/dito/components/GroupedCarousel/pc/index.less +65 -0
- package/es/composite-comp/dito/components/News/defaultJSON.js +172 -0
- package/{lib/composite-comp/dito/components/Orders → es/composite-comp/dito/components/News}/index.js +13 -13
- package/es/composite-comp/dito/components/News/pc/index.js +113 -0
- package/es/composite-comp/dito/components/News/pc/index.less +46 -0
- package/es/composite-comp/dito/components/Orders/defaultJSON.js +1 -1
- package/es/composite-comp/dito/components/PersonalInformation/defaultJSON.js +56 -2
- package/es/composite-comp/dito/components/PersonalInformation/mobile/index.js +147 -15
- package/es/composite-comp/dito/components/PersonalInformation/mobile/index.less +100 -8
- package/es/composite-comp/dito/components/Recommend/mobile/index.js +130 -14
- package/es/composite-comp/dito/components/SearchBanner/mobile/index.js +3 -11
- package/es/composite-comp/dito/components/SearchDITO/defaultJSON.js +221 -0
- package/es/composite-comp/dito/components/SearchDITO/index.js +86 -0
- package/es/composite-comp/dito/components/SearchDITO/pc/components/ConfirmModal/index.less +69 -0
- package/es/composite-comp/dito/components/SearchDITO/pc/components/Header/index.js +602 -0
- package/es/composite-comp/dito/components/SearchDITO/pc/components/Header/index.less +184 -0
- package/es/composite-comp/dito/components/SearchDITO/pc/components/VideoItem/index.js +153 -0
- package/es/composite-comp/dito/components/SearchDITO/pc/components/VideoItem/index.less +25 -0
- package/es/composite-comp/dito/components/SearchDITO/pc/imgs/avatar.png +0 -0
- package/es/composite-comp/dito/components/SearchDITO/pc/index.js +176 -0
- package/es/composite-comp/dito/components/SearchDITO/pc/index.less +57 -0
- package/es/composite-comp/dito/components/SlideImage/defaultJSON.js +138 -0
- package/es/composite-comp/dito/components/SlideImage/index.js +86 -0
- package/es/composite-comp/dito/components/SlideImage/pc/components/CardItem/index.js +105 -0
- package/es/composite-comp/dito/components/SlideImage/pc/components/CardItem/index.less +5 -0
- package/es/composite-comp/dito/components/SlideImage/pc/components/ParallaxScroll/index.js +170 -0
- package/es/composite-comp/dito/components/SlideImage/pc/components/ParallaxScroll/index.less +23 -0
- package/es/composite-comp/dito/components/SlideImage/pc/components/VideoItem/imgs/cursor.png +0 -0
- package/es/composite-comp/dito/components/SlideImage/pc/components/VideoItem/imgs/d.png +0 -0
- package/es/composite-comp/dito/components/SlideImage/pc/components/VideoItem/index.js +176 -0
- package/es/composite-comp/dito/components/SlideImage/pc/components/VideoItem/index.less +61 -0
- package/es/composite-comp/dito/components/SlideImage/pc/index.js +76 -0
- package/es/composite-comp/dito/config-panels/FlashDealConfig/FlashDealConfigTitle/index.js +7 -20
- package/es/composite-comp/dito/config-panels/FlashDealConfig/index.js +15 -1
- package/es/composite-comp/dito/config-panels/GroupedCarouselConfig/ConfigGroup/index.js +149 -0
- package/es/composite-comp/dito/config-panels/GroupedCarouselConfig/ConfigGroup/index.less +16 -0
- package/es/composite-comp/dito/config-panels/GroupedCarouselConfig/ConfigTitle/index.js +93 -0
- package/es/composite-comp/dito/config-panels/GroupedCarouselConfig/ConfigTitle/index.less +0 -0
- package/es/composite-comp/dito/config-panels/GroupedCarouselConfig/imgs/defaultImg.png +0 -0
- package/es/composite-comp/dito/config-panels/GroupedCarouselConfig/index.js +114 -0
- package/es/composite-comp/dito/config-panels/NewsConfig/ConfigGroup/index.js +148 -0
- package/es/composite-comp/dito/config-panels/NewsConfig/ConfigGroup/index.less +16 -0
- package/es/composite-comp/dito/config-panels/NewsConfig/ConfigTitle/index.js +101 -0
- package/es/composite-comp/dito/config-panels/NewsConfig/ConfigTitle/index.less +0 -0
- package/es/composite-comp/dito/config-panels/NewsConfig/imgs/defaultImg.png +0 -0
- package/{lib/composite-comp/dito/config-panels/OrdersConfig → es/composite-comp/dito/config-panels/NewsConfig}/index.js +40 -40
- package/es/composite-comp/dito/config-panels/{OrdersConfig/ConfigGroup → PersonalInformationConfig/OrdersConfigGroup}/index.js +2 -2
- package/es/composite-comp/dito/config-panels/PersonalInformationConfig/index.js +14 -4
- package/es/composite-comp/dito/config-panels/RecommendConfig/index.js +10 -4
- package/es/composite-comp/dito/config-panels/SearchDITOConfig/ConfigContent/index.js +165 -0
- package/es/composite-comp/dito/config-panels/SearchDITOConfig/ConfigContent/index.less +7 -0
- package/es/composite-comp/dito/config-panels/SearchDITOConfig/ConfigImageGroup/index.js +179 -0
- package/es/composite-comp/dito/config-panels/SearchDITOConfig/ConfigImageGroup/index.less +0 -0
- package/es/composite-comp/dito/config-panels/SearchDITOConfig/ConfigSetting/index.js +181 -0
- package/es/composite-comp/dito/config-panels/SearchDITOConfig/ConfigSetting/index.less +9 -0
- package/es/composite-comp/dito/config-panels/SearchDITOConfig/imgs/defaultImg.png +0 -0
- package/es/composite-comp/dito/config-panels/SearchDITOConfig/index.js +69 -0
- package/es/composite-comp/dito/config-panels/SlideImageConfig/ConfigGroup/index.js +150 -0
- package/es/composite-comp/dito/config-panels/SlideImageConfig/ConfigGroup/index.less +16 -0
- package/es/composite-comp/dito/config-panels/SlideImageConfig/imgs/defaultImg.png +0 -0
- package/es/composite-comp/dito/config-panels/SlideImageConfig/index.js +134 -0
- package/es/composite-comp/dito/second-config-panels/GroupedCarouselSecondConfig/index.js +196 -0
- package/es/composite-comp/dito/second-config-panels/NewsSecondConfig/index.js +133 -0
- package/es/composite-comp/dito/second-config-panels/NewsSecondConfig/index.less +8 -0
- package/es/composite-comp/dito/second-config-panels/PersonalInformationSecondConfig/index.js +64 -1
- package/es/composite-comp/dito/second-config-panels/SearchDITOSecondConfig/index.js +366 -0
- package/es/composite-comp/dito/second-config-panels/SearchDITOSecondConfig/index.less +79 -0
- package/es/composite-comp/dito/second-config-panels/SlideImageSecondConfig/index.js +243 -0
- package/es/composite-comp/dito/second-config-panels/SlideImageSecondConfig/index.less +71 -0
- package/es/composite-comp/monpay/components/MonpayRecommend/mobile/index.js +4 -3
- package/es/constants/component-types.js +27 -9
- package/es/constants/index.js +40 -20
- package/es/constants/layout.js +46 -2
- package/es/core/Designer/ConfigPanel/index.js +17 -1
- package/es/core/Renderer/index.js +37 -2
- package/es/decorator/compositeDecorator.js +5 -1
- package/es/decorator/metaDecorator.js +1 -2
- package/es/locale/ar/ar.json +11 -1
- package/es/locale/en/en.json +11 -1
- package/es/locale/es/es.json +11 -1
- package/es/meta-comp/components/Button/editable.js +3 -1
- package/es/meta-comp/components/Button/index.js +13 -4
- package/es/meta-comp/components/Button/index.less +8 -1
- package/es/meta-comp/components/Image/index.js +7 -2
- package/es/meta-comp/components/Image/index.less +7 -0
- package/es/meta-comp/components/Text/index.js +6 -2
- package/es/meta-comp/components/Text/index.less +3 -0
- package/es/mobx/Frame.js +12 -1
- package/es/mobx/Store.js +12 -0
- package/es/utils/androidUtil.js +10 -2
- package/es/utils/businessUtil.js +218 -3
- package/es/utils/commonUtil.js +155 -4
- package/es/utils/coreUtil.js +59 -4
- package/es/utils/messageUtil.js +40 -0
- package/es/utils/pluginsUtil.js +1 -0
- package/lib/assets/fonts/AvenirNext-Bold.ttf +0 -0
- package/lib/assets/fonts/AvenirNext-DemiBold.ttf +0 -0
- package/lib/assets/fonts/AvenirNext-Medium.ttf +0 -0
- package/lib/assets/fonts/AvenirNext-Regular.ttf +0 -0
- package/lib/assets/fonts/magic-box-iconfont.css +27 -3
- package/lib/assets/fonts/magic-box-iconfont.js +1 -1
- package/lib/assets/fonts/magic-box-iconfont.ttf +0 -0
- package/lib/assets/fonts/magic-box-iconfont.woff +0 -0
- package/lib/assets/fonts/magic-box-iconfont.woff2 +0 -0
- package/lib/assets/images/layout-icon/banner-slide-layout3.png +0 -0
- package/lib/assets/images/layout-icon/grouped-carousel-layout1.png +0 -0
- package/lib/assets/images/layout-icon/news-layout1.png +0 -0
- package/lib/assets/images/layout-icon/search-dito-layout1.png +0 -0
- package/lib/assets/images/layout-icon/slide-image-layout1.png +0 -0
- package/lib/assets/less/font.less +30 -0
- package/lib/assets/less/global.less +5 -0
- package/lib/common/CountDown/index.js +29 -2
- package/lib/common/CountDown/index.less +38 -5
- package/lib/common/LinkModal/ProductList/index.js +484 -0
- package/lib/common/LinkModal/ProductList/index.less +130 -0
- package/lib/common/LinkModal/index.js +8 -1
- package/lib/common/ProductCardModal/imgs/dot-icon.png +0 -0
- package/lib/common/ProductCardModal/index.js +255 -0
- package/lib/common/ProductCardModal/index.less +131 -0
- package/lib/common/Toast/index.js +30 -0
- package/lib/common/Toast/index.less +29 -0
- package/lib/common/UrlPicker/index.js +1 -1
- package/lib/common/Video/index.js +5 -3
- package/lib/common/VideoPC/background.png +0 -0
- package/lib/common/VideoPC/closeImg.png +0 -0
- package/lib/common/VideoPC/components/index.js +100 -0
- package/lib/common/VideoPC/components/index.less +62 -0
- package/lib/common/VideoPC/cover.png +0 -0
- package/lib/common/VideoPC/index.js +750 -0
- package/lib/common/VideoPC/index.less +79 -0
- package/lib/common/index.js +24 -0
- package/lib/composite-comp/common/components/ProductItem/index.js +15 -8
- package/lib/composite-comp/common/components/ProductItem/index.less +7 -0
- package/lib/composite-comp/common/config-panels/BackgroundConfig/index.js +15 -73
- package/lib/composite-comp/common/config-panels/SpacingConfig/index.js +30 -0
- package/lib/composite-comp/dito/components/CommonFunctions/defaultJSON.js +1 -1
- package/lib/composite-comp/dito/components/CommonFunctions/mobile/index.js +8 -0
- package/lib/composite-comp/dito/components/CommonFunctions/mobile/index.less +3 -0
- package/lib/composite-comp/dito/components/FlashDeal/defaultJSON.js +26 -12
- package/lib/composite-comp/dito/components/FlashDeal/mobile/index.js +15 -14
- package/lib/composite-comp/dito/components/FlashDeal/pc/ProductItem/index.js +197 -0
- package/lib/composite-comp/dito/components/FlashDeal/pc/ProductItem/index.less +100 -0
- package/lib/composite-comp/dito/components/FlashDeal/pc/index.js +18 -22
- package/lib/composite-comp/dito/components/FlashDeal/pc/index.less +19 -30
- package/lib/composite-comp/dito/components/GroupBuy/mobile/index.less +5 -2
- package/lib/composite-comp/dito/components/GroupedCarousel/defaultJSON.js +312 -0
- package/lib/composite-comp/dito/components/GroupedCarousel/index.js +86 -0
- package/lib/composite-comp/dito/components/GroupedCarousel/pc/index.js +189 -0
- package/lib/composite-comp/dito/components/GroupedCarousel/pc/index.less +65 -0
- package/lib/composite-comp/dito/components/News/defaultJSON.js +172 -0
- package/{es/composite-comp/dito/components/Orders → lib/composite-comp/dito/components/News}/index.js +13 -13
- package/lib/composite-comp/dito/components/News/pc/index.js +113 -0
- package/lib/composite-comp/dito/components/News/pc/index.less +46 -0
- package/lib/composite-comp/dito/components/Orders/defaultJSON.js +1 -1
- package/lib/composite-comp/dito/components/PersonalInformation/defaultJSON.js +56 -2
- package/lib/composite-comp/dito/components/PersonalInformation/mobile/index.js +147 -15
- package/lib/composite-comp/dito/components/PersonalInformation/mobile/index.less +100 -8
- package/lib/composite-comp/dito/components/Recommend/mobile/index.js +130 -14
- package/lib/composite-comp/dito/components/SearchBanner/mobile/index.js +3 -11
- package/lib/composite-comp/dito/components/SearchDITO/defaultJSON.js +221 -0
- package/lib/composite-comp/dito/components/SearchDITO/index.js +86 -0
- package/lib/composite-comp/dito/components/SearchDITO/pc/components/ConfirmModal/index.less +69 -0
- package/lib/composite-comp/dito/components/SearchDITO/pc/components/Header/index.js +602 -0
- package/lib/composite-comp/dito/components/SearchDITO/pc/components/Header/index.less +184 -0
- package/lib/composite-comp/dito/components/SearchDITO/pc/components/VideoItem/index.js +153 -0
- package/lib/composite-comp/dito/components/SearchDITO/pc/components/VideoItem/index.less +25 -0
- package/lib/composite-comp/dito/components/SearchDITO/pc/imgs/avatar.png +0 -0
- package/lib/composite-comp/dito/components/SearchDITO/pc/index.js +176 -0
- package/lib/composite-comp/dito/components/SearchDITO/pc/index.less +57 -0
- package/lib/composite-comp/dito/components/SlideImage/defaultJSON.js +138 -0
- package/lib/composite-comp/dito/components/SlideImage/index.js +86 -0
- package/lib/composite-comp/dito/components/SlideImage/pc/components/CardItem/index.js +105 -0
- package/lib/composite-comp/dito/components/SlideImage/pc/components/CardItem/index.less +5 -0
- package/lib/composite-comp/dito/components/SlideImage/pc/components/ParallaxScroll/index.js +170 -0
- package/lib/composite-comp/dito/components/SlideImage/pc/components/ParallaxScroll/index.less +23 -0
- package/lib/composite-comp/dito/components/SlideImage/pc/components/VideoItem/imgs/cursor.png +0 -0
- package/lib/composite-comp/dito/components/SlideImage/pc/components/VideoItem/imgs/d.png +0 -0
- package/lib/composite-comp/dito/components/SlideImage/pc/components/VideoItem/index.js +176 -0
- package/lib/composite-comp/dito/components/SlideImage/pc/components/VideoItem/index.less +61 -0
- package/lib/composite-comp/dito/components/SlideImage/pc/index.js +76 -0
- package/lib/composite-comp/dito/config-panels/FlashDealConfig/FlashDealConfigTitle/index.js +7 -20
- package/lib/composite-comp/dito/config-panels/FlashDealConfig/index.js +15 -1
- package/lib/composite-comp/dito/config-panels/GroupedCarouselConfig/ConfigGroup/index.js +149 -0
- package/lib/composite-comp/dito/config-panels/GroupedCarouselConfig/ConfigGroup/index.less +16 -0
- package/lib/composite-comp/dito/config-panels/GroupedCarouselConfig/ConfigTitle/index.js +93 -0
- package/lib/composite-comp/dito/config-panels/GroupedCarouselConfig/ConfigTitle/index.less +0 -0
- package/lib/composite-comp/dito/config-panels/GroupedCarouselConfig/imgs/defaultImg.png +0 -0
- package/lib/composite-comp/dito/config-panels/GroupedCarouselConfig/index.js +114 -0
- package/lib/composite-comp/dito/config-panels/NewsConfig/ConfigGroup/index.js +148 -0
- package/lib/composite-comp/dito/config-panels/NewsConfig/ConfigGroup/index.less +16 -0
- package/lib/composite-comp/dito/config-panels/NewsConfig/ConfigTitle/index.js +101 -0
- package/lib/composite-comp/dito/config-panels/NewsConfig/ConfigTitle/index.less +0 -0
- package/lib/composite-comp/dito/config-panels/NewsConfig/imgs/defaultImg.png +0 -0
- package/{es/composite-comp/dito/config-panels/OrdersConfig → lib/composite-comp/dito/config-panels/NewsConfig}/index.js +40 -40
- package/lib/composite-comp/dito/config-panels/{OrdersConfig/ConfigGroup → PersonalInformationConfig/OrdersConfigGroup}/index.js +2 -2
- package/lib/composite-comp/dito/config-panels/PersonalInformationConfig/index.js +14 -4
- package/lib/composite-comp/dito/config-panels/RecommendConfig/index.js +10 -4
- package/lib/composite-comp/dito/config-panels/SearchDITOConfig/ConfigContent/index.js +165 -0
- package/lib/composite-comp/dito/config-panels/SearchDITOConfig/ConfigContent/index.less +7 -0
- package/lib/composite-comp/dito/config-panels/SearchDITOConfig/ConfigImageGroup/index.js +179 -0
- package/lib/composite-comp/dito/config-panels/SearchDITOConfig/ConfigImageGroup/index.less +0 -0
- package/lib/composite-comp/dito/config-panels/SearchDITOConfig/ConfigSetting/index.js +181 -0
- package/lib/composite-comp/dito/config-panels/SearchDITOConfig/ConfigSetting/index.less +9 -0
- package/lib/composite-comp/dito/config-panels/SearchDITOConfig/imgs/defaultImg.png +0 -0
- package/lib/composite-comp/dito/config-panels/SearchDITOConfig/index.js +69 -0
- package/lib/composite-comp/dito/config-panels/SlideImageConfig/ConfigGroup/index.js +150 -0
- package/lib/composite-comp/dito/config-panels/SlideImageConfig/ConfigGroup/index.less +16 -0
- package/lib/composite-comp/dito/config-panels/SlideImageConfig/imgs/defaultImg.png +0 -0
- package/lib/composite-comp/dito/config-panels/SlideImageConfig/index.js +134 -0
- package/lib/composite-comp/dito/second-config-panels/GroupedCarouselSecondConfig/index.js +196 -0
- package/lib/composite-comp/dito/second-config-panels/NewsSecondConfig/index.js +133 -0
- package/lib/composite-comp/dito/second-config-panels/NewsSecondConfig/index.less +8 -0
- package/lib/composite-comp/dito/second-config-panels/PersonalInformationSecondConfig/index.js +64 -1
- package/lib/composite-comp/dito/second-config-panels/SearchDITOSecondConfig/index.js +366 -0
- package/lib/composite-comp/dito/second-config-panels/SearchDITOSecondConfig/index.less +79 -0
- package/lib/composite-comp/dito/second-config-panels/SlideImageSecondConfig/index.js +243 -0
- package/lib/composite-comp/dito/second-config-panels/SlideImageSecondConfig/index.less +71 -0
- package/lib/composite-comp/monpay/components/MonpayRecommend/mobile/index.js +4 -3
- package/lib/constants/component-types.js +27 -9
- package/lib/constants/index.js +40 -20
- package/lib/constants/layout.js +46 -2
- package/lib/core/Designer/ConfigPanel/index.js +17 -1
- package/lib/core/Renderer/index.js +37 -2
- package/lib/decorator/compositeDecorator.js +5 -1
- package/lib/decorator/metaDecorator.js +1 -2
- package/lib/locale/ar/ar.json +11 -1
- package/lib/locale/en/en.json +11 -1
- package/lib/locale/es/es.json +11 -1
- package/lib/meta-comp/components/Button/editable.js +3 -1
- package/lib/meta-comp/components/Button/index.js +13 -4
- package/lib/meta-comp/components/Button/index.less +8 -1
- package/lib/meta-comp/components/Image/index.js +7 -2
- package/lib/meta-comp/components/Image/index.less +7 -0
- package/lib/meta-comp/components/Text/index.js +6 -2
- package/lib/meta-comp/components/Text/index.less +3 -0
- package/lib/mobx/Frame.js +12 -1
- package/lib/mobx/Store.js +12 -0
- package/lib/utils/androidUtil.js +10 -2
- package/lib/utils/businessUtil.js +218 -3
- package/lib/utils/commonUtil.js +155 -4
- package/lib/utils/coreUtil.js +59 -4
- package/lib/utils/messageUtil.js +40 -0
- package/lib/utils/pluginsUtil.js +1 -0
- package/package.json +5 -2
- package/es/composite-comp/dito/components/FlashDeal/pc/imgs/defImg1.png +0 -0
- package/es/composite-comp/dito/components/FlashDeal/pc/imgs/defImg2.png +0 -0
- package/es/composite-comp/dito/components/FlashDeal/pc/imgs/defImg3.png +0 -0
- package/es/composite-comp/dito/components/Orders/mobile/index.js +0 -352
- package/es/composite-comp/dito/components/Orders/mobile/index.less +0 -86
- package/es/composite-comp/dito/second-config-panels/OrdersSecondConfig/index.less +0 -9
- package/lib/composite-comp/dito/components/FlashDeal/pc/imgs/defImg1.png +0 -0
- package/lib/composite-comp/dito/components/FlashDeal/pc/imgs/defImg2.png +0 -0
- package/lib/composite-comp/dito/components/FlashDeal/pc/imgs/defImg3.png +0 -0
- package/lib/composite-comp/dito/components/Orders/mobile/index.js +0 -352
- package/lib/composite-comp/dito/components/Orders/mobile/index.less +0 -86
- package/lib/composite-comp/dito/second-config-panels/OrdersSecondConfig/index.less +0 -9
- /package/es/composite-comp/dito/config-panels/PersonalInformationConfig/{ConfigGroup → PersonInfoConfigGroup}/index.js +0 -0
- /package/lib/composite-comp/dito/config-panels/PersonalInformationConfig/{ConfigGroup → PersonInfoConfigGroup}/index.js +0 -0
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.groupSourceJSON = exports.getDefaultJSON = void 0;
|
|
7
|
+
|
|
8
|
+
var _uuid = require("uuid");
|
|
9
|
+
|
|
10
|
+
var groupSourceJSON = function groupSourceJSON(parentId) {
|
|
11
|
+
var groupId = (0, _uuid.v4)();
|
|
12
|
+
return {
|
|
13
|
+
id: groupId,
|
|
14
|
+
parentId: parentId,
|
|
15
|
+
overilay: {
|
|
16
|
+
open: true,
|
|
17
|
+
content: {
|
|
18
|
+
h5Name: 'Video Name',
|
|
19
|
+
pcName: 'Video Name',
|
|
20
|
+
h5ImgSrc: '',
|
|
21
|
+
pcImgSrc: '',
|
|
22
|
+
clickUrl: ''
|
|
23
|
+
},
|
|
24
|
+
hover: {}
|
|
25
|
+
},
|
|
26
|
+
video: {
|
|
27
|
+
sourceType: 'Upload',
|
|
28
|
+
sourceUrl: '',
|
|
29
|
+
startAt: '',
|
|
30
|
+
progressBar: true,
|
|
31
|
+
loop: true,
|
|
32
|
+
autoplay: false,
|
|
33
|
+
videoSound: false,
|
|
34
|
+
speed: 1,
|
|
35
|
+
playPosition: 'Play in Box',
|
|
36
|
+
playButton: 'Middle'
|
|
37
|
+
},
|
|
38
|
+
playIcon: {
|
|
39
|
+
open: true,
|
|
40
|
+
parentId: groupId,
|
|
41
|
+
id: (0, _uuid.v4)(),
|
|
42
|
+
type: 'PLAY',
|
|
43
|
+
size: 48,
|
|
44
|
+
pcSize: 60,
|
|
45
|
+
iconType: 'light-playicon-01',
|
|
46
|
+
iconColor: 'Light'
|
|
47
|
+
},
|
|
48
|
+
groupName: {
|
|
49
|
+
parentId: groupId,
|
|
50
|
+
id: (0, _uuid.v4)(),
|
|
51
|
+
open: true,
|
|
52
|
+
type: 'TEXT',
|
|
53
|
+
specialContent: [],
|
|
54
|
+
text: 'Group Name',
|
|
55
|
+
content: {
|
|
56
|
+
sizeType: 'Customize font styles',
|
|
57
|
+
fontWeight: 600,
|
|
58
|
+
pcFontSize: 22,
|
|
59
|
+
color: '#232F46',
|
|
60
|
+
textAlign: 'left'
|
|
61
|
+
},
|
|
62
|
+
underline: {
|
|
63
|
+
open: false,
|
|
64
|
+
textDecorationColor: '',
|
|
65
|
+
textDecorationStyle: 'solid'
|
|
66
|
+
},
|
|
67
|
+
vertical: {}
|
|
68
|
+
},
|
|
69
|
+
clickUrl: '',
|
|
70
|
+
background: {
|
|
71
|
+
opacity: 100,
|
|
72
|
+
color: '#fff',
|
|
73
|
+
image: '',
|
|
74
|
+
bgType: 'image'
|
|
75
|
+
}
|
|
76
|
+
};
|
|
77
|
+
};
|
|
78
|
+
|
|
79
|
+
exports.groupSourceJSON = groupSourceJSON;
|
|
80
|
+
|
|
81
|
+
var getDefaultJSON = function getDefaultJSON() {
|
|
82
|
+
var groupId = (0, _uuid.v4)();
|
|
83
|
+
return {
|
|
84
|
+
id: groupId,
|
|
85
|
+
type: 'SLIDE_IMAGE',
|
|
86
|
+
content: {
|
|
87
|
+
moveIcon: {
|
|
88
|
+
id: (0, _uuid.v4)(),
|
|
89
|
+
open: true,
|
|
90
|
+
type: 'IMAGE',
|
|
91
|
+
content: {
|
|
92
|
+
h5Name: 'Image Name',
|
|
93
|
+
pcName: 'Image Name',
|
|
94
|
+
h5ImgSrc: '',
|
|
95
|
+
pcImgSrc: '',
|
|
96
|
+
clickUrl: ''
|
|
97
|
+
},
|
|
98
|
+
hover: {
|
|
99
|
+
open: false,
|
|
100
|
+
backgroundType: 'enlarge',
|
|
101
|
+
magnification: 1.5,
|
|
102
|
+
pcImgHoverUrl: '',
|
|
103
|
+
h5ImgHoverUrl: ''
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
},
|
|
107
|
+
groupSource: [groupSourceJSON(groupId), groupSourceJSON(groupId), groupSourceJSON(groupId)],
|
|
108
|
+
spacing: {
|
|
109
|
+
pc: {
|
|
110
|
+
paddingTop: 0,
|
|
111
|
+
paddingBottom: 0,
|
|
112
|
+
paddingLeft: 0,
|
|
113
|
+
paddingRight: 0,
|
|
114
|
+
marginBottom: window.magicDesign.compSpacing * 1.5,
|
|
115
|
+
lineSpace: 68,
|
|
116
|
+
columnSpace: 48
|
|
117
|
+
},
|
|
118
|
+
mobile: {
|
|
119
|
+
paddingTop: 0,
|
|
120
|
+
paddingBottom: 0,
|
|
121
|
+
paddingLeft: 0,
|
|
122
|
+
paddingRight: 0,
|
|
123
|
+
marginBottom: window.magicDesign.compSpacing
|
|
124
|
+
}
|
|
125
|
+
},
|
|
126
|
+
customize: {
|
|
127
|
+
layout: 'layout1'
|
|
128
|
+
},
|
|
129
|
+
background: {
|
|
130
|
+
opacity: 100,
|
|
131
|
+
color: '#fff',
|
|
132
|
+
image: '',
|
|
133
|
+
bgType: 'color'
|
|
134
|
+
}
|
|
135
|
+
};
|
|
136
|
+
};
|
|
137
|
+
|
|
138
|
+
exports.getDefaultJSON = getDefaultJSON;
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = void 0;
|
|
7
|
+
|
|
8
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
9
|
+
|
|
10
|
+
var _pc = _interopRequireDefault(require("./pc"));
|
|
11
|
+
|
|
12
|
+
var _defaultJSON = require("./defaultJSON");
|
|
13
|
+
|
|
14
|
+
var _coreUtil = require("../../../../utils/coreUtil");
|
|
15
|
+
|
|
16
|
+
var _compositeDecorator = _interopRequireDefault(require("../../../../decorator/compositeDecorator"));
|
|
17
|
+
|
|
18
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
19
|
+
|
|
20
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
21
|
+
|
|
22
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
23
|
+
|
|
24
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
25
|
+
|
|
26
|
+
var __extends = void 0 && (void 0).__extends || function () {
|
|
27
|
+
var _extendStatics = function extendStatics(d, b) {
|
|
28
|
+
_extendStatics = Object.setPrototypeOf || {
|
|
29
|
+
__proto__: []
|
|
30
|
+
} instanceof Array && function (d, b) {
|
|
31
|
+
d.__proto__ = b;
|
|
32
|
+
} || function (d, b) {
|
|
33
|
+
for (var p in b) {
|
|
34
|
+
if (b.hasOwnProperty(p)) d[p] = b[p];
|
|
35
|
+
}
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
return _extendStatics(d, b);
|
|
39
|
+
};
|
|
40
|
+
|
|
41
|
+
return function (d, b) {
|
|
42
|
+
_extendStatics(d, b);
|
|
43
|
+
|
|
44
|
+
function __() {
|
|
45
|
+
this.constructor = d;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
49
|
+
};
|
|
50
|
+
}();
|
|
51
|
+
|
|
52
|
+
var __decorate = void 0 && (void 0).__decorate || function (decorators, target, key, desc) {
|
|
53
|
+
var c = arguments.length,
|
|
54
|
+
r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc,
|
|
55
|
+
d;
|
|
56
|
+
if ((typeof Reflect === "undefined" ? "undefined" : _typeof(Reflect)) === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) {
|
|
57
|
+
if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
58
|
+
}
|
|
59
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
60
|
+
};
|
|
61
|
+
|
|
62
|
+
var SlideImage =
|
|
63
|
+
/** @class */
|
|
64
|
+
function (_super) {
|
|
65
|
+
__extends(SlideImage, _super);
|
|
66
|
+
|
|
67
|
+
function SlideImage() {
|
|
68
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
SlideImage.prototype.render = function () {
|
|
72
|
+
var nodeData = this.props.nodeData;
|
|
73
|
+
return /*#__PURE__*/_react["default"].createElement("div", null, (0, _coreUtil.isPc)() ? /*#__PURE__*/_react["default"].createElement(_pc["default"], {
|
|
74
|
+
panelProps: nodeData
|
|
75
|
+
}) : null);
|
|
76
|
+
};
|
|
77
|
+
|
|
78
|
+
SlideImage.defaultProps = {};
|
|
79
|
+
SlideImage.type = 'SLIDE_IMAGE';
|
|
80
|
+
SlideImage.getDefaultJSON = _defaultJSON.getDefaultJSON;
|
|
81
|
+
SlideImage = __decorate([_compositeDecorator["default"]], SlideImage);
|
|
82
|
+
return SlideImage;
|
|
83
|
+
}(_react.Component);
|
|
84
|
+
|
|
85
|
+
var _default = SlideImage;
|
|
86
|
+
exports["default"] = _default;
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = void 0;
|
|
7
|
+
|
|
8
|
+
var _react = _interopRequireDefault(require("react"));
|
|
9
|
+
|
|
10
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
11
|
+
|
|
12
|
+
var _components = require("../../../../../../../meta-comp/components");
|
|
13
|
+
|
|
14
|
+
var _VideoItem = _interopRequireDefault(require("../VideoItem"));
|
|
15
|
+
|
|
16
|
+
require("./index.less");
|
|
17
|
+
|
|
18
|
+
var _coreUtil = require("../../../../../../../utils/coreUtil");
|
|
19
|
+
|
|
20
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
21
|
+
|
|
22
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
23
|
+
|
|
24
|
+
var __extends = void 0 && (void 0).__extends || function () {
|
|
25
|
+
var _extendStatics = function extendStatics(d, b) {
|
|
26
|
+
_extendStatics = Object.setPrototypeOf || {
|
|
27
|
+
__proto__: []
|
|
28
|
+
} instanceof Array && function (d, b) {
|
|
29
|
+
d.__proto__ = b;
|
|
30
|
+
} || function (d, b) {
|
|
31
|
+
for (var p in b) {
|
|
32
|
+
if (b.hasOwnProperty(p)) d[p] = b[p];
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
return _extendStatics(d, b);
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
return function (d, b) {
|
|
40
|
+
_extendStatics(d, b);
|
|
41
|
+
|
|
42
|
+
function __() {
|
|
43
|
+
this.constructor = d;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
47
|
+
};
|
|
48
|
+
}();
|
|
49
|
+
|
|
50
|
+
var __rest = void 0 && (void 0).__rest || function (s, e) {
|
|
51
|
+
var t = {};
|
|
52
|
+
|
|
53
|
+
for (var p in s) {
|
|
54
|
+
if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
58
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
|
|
59
|
+
}
|
|
60
|
+
return t;
|
|
61
|
+
};
|
|
62
|
+
|
|
63
|
+
var CardItem =
|
|
64
|
+
/** @class */
|
|
65
|
+
function (_super) {
|
|
66
|
+
__extends(CardItem, _super);
|
|
67
|
+
|
|
68
|
+
function CardItem() {
|
|
69
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
CardItem.prototype.render = function () {
|
|
73
|
+
var _a = this.props,
|
|
74
|
+
data = _a.data,
|
|
75
|
+
onLoad = _a.onLoad,
|
|
76
|
+
moveIcon = _a.moveIcon,
|
|
77
|
+
rest = __rest(_a, ["data", "onLoad", "moveIcon"]);
|
|
78
|
+
|
|
79
|
+
return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement("div", _extends({
|
|
80
|
+
className: (0, _classnames["default"])('slide-image-card-item-wrap'),
|
|
81
|
+
onClick: function onClick() {
|
|
82
|
+
return (0, _coreUtil.clickUrl)(data.clickUrl || '');
|
|
83
|
+
}
|
|
84
|
+
}, rest), /*#__PURE__*/_react["default"].createElement(_VideoItem["default"], {
|
|
85
|
+
cursor: data.clickUrl || '',
|
|
86
|
+
data: data,
|
|
87
|
+
moveIcon: moveIcon,
|
|
88
|
+
onLoad: onLoad
|
|
89
|
+
}), data.groupName.open && /*#__PURE__*/_react["default"].createElement(_components.MetaText, {
|
|
90
|
+
className: "text",
|
|
91
|
+
data: data.groupName,
|
|
92
|
+
style: {
|
|
93
|
+
cursor: data.clickUrl ? 'pointer' : 'unset'
|
|
94
|
+
}
|
|
95
|
+
})));
|
|
96
|
+
};
|
|
97
|
+
|
|
98
|
+
CardItem.defaultProps = {
|
|
99
|
+
data: {}
|
|
100
|
+
};
|
|
101
|
+
return CardItem;
|
|
102
|
+
}(_react["default"].Component);
|
|
103
|
+
|
|
104
|
+
var _default = CardItem;
|
|
105
|
+
exports["default"] = _default;
|
|
@@ -0,0 +1,170 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports["default"] = ParallaxScroll;
|
|
9
|
+
|
|
10
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
+
|
|
12
|
+
var _framerMotion = require("framer-motion");
|
|
13
|
+
|
|
14
|
+
var _debounce = _interopRequireDefault(require("lodash/debounce"));
|
|
15
|
+
|
|
16
|
+
var _CardItem = _interopRequireDefault(require("../CardItem"));
|
|
17
|
+
|
|
18
|
+
require("./index.less");
|
|
19
|
+
|
|
20
|
+
var _coreUtil = require("../../../../../../../utils/coreUtil");
|
|
21
|
+
|
|
22
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
23
|
+
|
|
24
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
25
|
+
|
|
26
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
27
|
+
|
|
28
|
+
var num = 0;
|
|
29
|
+
|
|
30
|
+
function ParallaxScroll(_a) {
|
|
31
|
+
var moveIcon = _a.moveIcon,
|
|
32
|
+
source = _a.source,
|
|
33
|
+
xGap = _a.xGap,
|
|
34
|
+
yGap = _a.yGap;
|
|
35
|
+
|
|
36
|
+
var _b = (0, _react.useState)(0),
|
|
37
|
+
colOneScrollY = _b[0],
|
|
38
|
+
setColOneScrollY = _b[1];
|
|
39
|
+
|
|
40
|
+
var _c = (0, _react.useState)(0),
|
|
41
|
+
colTwoScrollY = _c[0],
|
|
42
|
+
setColTwoScrollY = _c[1];
|
|
43
|
+
|
|
44
|
+
var _d = (0, _react.useState)(0),
|
|
45
|
+
colThreeScrollY = _d[0],
|
|
46
|
+
setColThreeScrollY = _d[1];
|
|
47
|
+
|
|
48
|
+
var third = Math.ceil(source.length / 3);
|
|
49
|
+
var firstPart = source.slice(0, third);
|
|
50
|
+
var secondPart = source.slice(third, 2 * third);
|
|
51
|
+
var thirdPart = source.slice(2 * third);
|
|
52
|
+
var gridRef = (0, _react.useRef)(null);
|
|
53
|
+
var colOneRef = (0, _react.useRef)(null);
|
|
54
|
+
var colTwoRef = (0, _react.useRef)(null);
|
|
55
|
+
var colThreeRef = (0, _react.useRef)(null); // 获取视口滚动信息
|
|
56
|
+
|
|
57
|
+
var scrollYProgress = (0, _framerMotion.useScroll)({
|
|
58
|
+
target: gridRef,
|
|
59
|
+
// 定义滚动监听的起始和结束位置
|
|
60
|
+
offset: ['start start', 'end end']
|
|
61
|
+
}).scrollYProgress;
|
|
62
|
+
var translateFirst = (0, _framerMotion.useTransform)(scrollYProgress, [0, 1], [0, colOneScrollY]);
|
|
63
|
+
var translateSecond = (0, _framerMotion.useTransform)(scrollYProgress, [0, 1], [0, colTwoScrollY]);
|
|
64
|
+
var translateThird = (0, _framerMotion.useTransform)(scrollYProgress, [0, 1], [0, colThreeScrollY]);
|
|
65
|
+
|
|
66
|
+
var initLayout = function initLayout() {
|
|
67
|
+
var _a, _b, _c;
|
|
68
|
+
|
|
69
|
+
var colOneHeight = (_a = colOneRef.current) === null || _a === void 0 ? void 0 : _a.offsetHeight;
|
|
70
|
+
var colTwoHeight = (_b = colTwoRef.current) === null || _b === void 0 ? void 0 : _b.offsetHeight;
|
|
71
|
+
var colThreeHeight = (_c = colThreeRef.current) === null || _c === void 0 ? void 0 : _c.offsetHeight;
|
|
72
|
+
var colHeights = [colOneHeight, colTwoHeight, colThreeHeight];
|
|
73
|
+
var space = Math.max.apply(Math, colHeights) - Math.min.apply(Math, colHeights) - 20;
|
|
74
|
+
var minHeightIndex = colHeights.indexOf(Math.min.apply(Math, colHeights));
|
|
75
|
+
|
|
76
|
+
if (minHeightIndex === 0) {
|
|
77
|
+
setColOneScrollY(space);
|
|
78
|
+
setColTwoScrollY(colOneHeight - colTwoHeight + space);
|
|
79
|
+
setColThreeScrollY(colOneHeight - colThreeHeight + space);
|
|
80
|
+
} else if (minHeightIndex === 1) {
|
|
81
|
+
setColOneScrollY(colTwoHeight - colOneHeight + space);
|
|
82
|
+
setColTwoScrollY(space);
|
|
83
|
+
setColThreeScrollY(colTwoHeight - colThreeHeight + space);
|
|
84
|
+
} else {
|
|
85
|
+
setColOneScrollY(colThreeHeight - colOneHeight + space);
|
|
86
|
+
setColTwoScrollY(colThreeHeight - colTwoHeight + space);
|
|
87
|
+
setColThreeScrollY(space);
|
|
88
|
+
}
|
|
89
|
+
};
|
|
90
|
+
|
|
91
|
+
var onLoad = function onLoad() {
|
|
92
|
+
if (num < source.length - 1) {
|
|
93
|
+
num += 1;
|
|
94
|
+
} else {
|
|
95
|
+
initLayout();
|
|
96
|
+
setTimeout(function () {
|
|
97
|
+
initLayout();
|
|
98
|
+
}, 1000);
|
|
99
|
+
}
|
|
100
|
+
};
|
|
101
|
+
|
|
102
|
+
(0, _react.useEffect)(function () {
|
|
103
|
+
if (!(0, _coreUtil.isDesignMode)()) {
|
|
104
|
+
window.addEventListener('resize', (0, _debounce["default"])(initLayout, 200));
|
|
105
|
+
return function () {
|
|
106
|
+
window.removeEventListener('resize', initLayout);
|
|
107
|
+
};
|
|
108
|
+
}
|
|
109
|
+
}, [scrollYProgress]);
|
|
110
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
111
|
+
className: "m-parallax-scroll"
|
|
112
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
113
|
+
ref: gridRef,
|
|
114
|
+
className: "grid-cols-3",
|
|
115
|
+
style: {
|
|
116
|
+
gap: xGap + 'px'
|
|
117
|
+
}
|
|
118
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
119
|
+
ref: colOneRef,
|
|
120
|
+
className: "grid",
|
|
121
|
+
style: {
|
|
122
|
+
gap: yGap + 'px'
|
|
123
|
+
}
|
|
124
|
+
}, firstPart.map(function (el, idx) {
|
|
125
|
+
return /*#__PURE__*/_react["default"].createElement(_framerMotion.motion.div, {
|
|
126
|
+
key: 'grid-1' + idx,
|
|
127
|
+
style: {
|
|
128
|
+
y: translateFirst
|
|
129
|
+
}
|
|
130
|
+
}, /*#__PURE__*/_react["default"].createElement(_CardItem["default"], {
|
|
131
|
+
data: el,
|
|
132
|
+
moveIcon: moveIcon,
|
|
133
|
+
onLoad: onLoad
|
|
134
|
+
}));
|
|
135
|
+
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
136
|
+
ref: colTwoRef,
|
|
137
|
+
className: "grid",
|
|
138
|
+
style: {
|
|
139
|
+
gap: yGap + 'px'
|
|
140
|
+
}
|
|
141
|
+
}, secondPart.map(function (el, idx) {
|
|
142
|
+
return /*#__PURE__*/_react["default"].createElement(_framerMotion.motion.div, {
|
|
143
|
+
key: 'grid-2' + idx,
|
|
144
|
+
style: {
|
|
145
|
+
y: translateSecond
|
|
146
|
+
}
|
|
147
|
+
}, /*#__PURE__*/_react["default"].createElement(_CardItem["default"], {
|
|
148
|
+
data: el,
|
|
149
|
+
moveIcon: moveIcon,
|
|
150
|
+
onLoad: onLoad
|
|
151
|
+
}));
|
|
152
|
+
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
153
|
+
ref: colThreeRef,
|
|
154
|
+
className: "grid",
|
|
155
|
+
style: {
|
|
156
|
+
gap: yGap + 'px'
|
|
157
|
+
}
|
|
158
|
+
}, thirdPart.map(function (el, idx) {
|
|
159
|
+
return /*#__PURE__*/_react["default"].createElement(_framerMotion.motion.div, {
|
|
160
|
+
key: 'grid-3' + idx,
|
|
161
|
+
style: {
|
|
162
|
+
y: translateThird
|
|
163
|
+
}
|
|
164
|
+
}, /*#__PURE__*/_react["default"].createElement(_CardItem["default"], {
|
|
165
|
+
data: el,
|
|
166
|
+
moveIcon: moveIcon,
|
|
167
|
+
onLoad: onLoad
|
|
168
|
+
}));
|
|
169
|
+
}))));
|
|
170
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
.m-parallax-scroll {
|
|
2
|
+
|
|
3
|
+
.grid-cols-3 {
|
|
4
|
+
display: grid;
|
|
5
|
+
align-content: start;
|
|
6
|
+
grid-template-columns: repeat(3, minmax(0, 1fr));
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.grid {
|
|
10
|
+
display: grid;
|
|
11
|
+
align-content: start;
|
|
12
|
+
height: fit-content;
|
|
13
|
+
|
|
14
|
+
>div {
|
|
15
|
+
z-index: 2;
|
|
16
|
+
|
|
17
|
+
&:hover {
|
|
18
|
+
z-index: 1;
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
}
|
|
Binary file
|