@fonixtree/magic-design 2.0.200 → 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/Montserrat-Bold.ttf +0 -0
- package/es/assets/fonts/Montserrat-Medium.ttf +0 -0
- package/es/assets/fonts/Montserrat-Regular.ttf +0 -0
- package/es/assets/fonts/Montserrat-SemiBold.ttf +0 -0
- package/es/assets/fonts/magic-box-iconfont.css +38 -6
- 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/base64/index.js +8 -2
- 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/ColorPickerInput/index.less +2 -0
- package/es/common/CountDown/index.js +29 -2
- package/es/common/CountDown/index.less +38 -5
- package/es/common/ErrorBoundary/index.js +90 -0
- package/es/common/FontStyles/index.less +1 -1
- 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 +32 -0
- package/es/composite-comp/common/components/ImageLabel/index.js +2 -2
- package/es/composite-comp/common/components/ImageLabel/index.less +23 -7
- package/es/composite-comp/common/components/ProductItem/index.js +41 -24
- package/es/composite-comp/common/components/ProductItem/index.less +17 -15
- package/es/composite-comp/common/config-panels/BackgroundConfig/index.js +16 -12
- package/es/composite-comp/common/config-panels/SpacingConfig/index.js +30 -0
- package/es/composite-comp/dito/components/Bargain/defaultJSON.js +24 -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 +49 -11
- package/es/composite-comp/dito/components/FlashDeal/mobile/index.js +15 -14
- package/es/composite-comp/dito/components/FlashDeal/mobile/index.less +9 -1
- 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/defaultJSON.js +24 -0
- package/es/composite-comp/dito/components/GroupBuy/mobile/index.js +8 -5
- 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 +75 -2
- package/es/composite-comp/dito/components/PersonalInformation/mobile/images/avatar.png +0 -0
- package/es/composite-comp/dito/components/PersonalInformation/mobile/index.js +159 -21
- package/es/composite-comp/dito/components/PersonalInformation/mobile/index.less +108 -9
- package/es/composite-comp/dito/components/Recommend/defaultJSON.js +55 -1
- package/es/composite-comp/dito/components/Recommend/mobile/imgs/card.png +0 -0
- package/es/composite-comp/dito/components/Recommend/mobile/index.js +177 -20
- package/es/composite-comp/dito/components/Recommend/mobile/index.less +24 -1
- package/es/composite-comp/dito/components/SearchBanner/defaultJSON.js +234 -0
- package/es/composite-comp/dito/components/SearchBanner/imgs/defaultImg.png +0 -0
- package/es/composite-comp/dito/components/SearchBanner/imgs/pcDefImg1.png +0 -0
- package/es/composite-comp/dito/components/SearchBanner/index.js +108 -0
- package/es/composite-comp/dito/components/SearchBanner/mobile/index.js +293 -0
- package/es/composite-comp/dito/components/SearchBanner/mobile/index.less +108 -0
- 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/SignBoard/mobile/index.js +1 -1
- 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/BargainConfig/FlashDealConfigContent/index.js +7 -0
- package/es/composite-comp/dito/config-panels/FlashDealConfig/FlashDealConfigContent/index.js +7 -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/GroupBuyConfig/GroupBuyConfigContent/index.js +7 -0
- 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/PersonalInformationConfig/ConfigDecoration/index.js +91 -0
- package/es/composite-comp/dito/config-panels/PersonalInformationConfig/ConfigDecoration/index.less +9 -0
- 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 +23 -5
- package/es/composite-comp/dito/config-panels/RecommendConfig/RecommendConfigContent/index.js +17 -1
- package/es/composite-comp/dito/config-panels/RecommendConfig/index.js +10 -3
- package/es/composite-comp/dito/config-panels/SearchBannerConfig/ConfigContent/index.js +197 -0
- package/es/composite-comp/dito/config-panels/SearchBannerConfig/ConfigContent/index.less +7 -0
- package/es/composite-comp/dito/config-panels/SearchBannerConfig/ConfigImageGroup/index.js +148 -0
- package/es/composite-comp/dito/config-panels/SearchBannerConfig/ConfigImageGroup/index.less +0 -0
- package/es/composite-comp/dito/config-panels/SearchBannerConfig/ConfigSetting/index.js +226 -0
- package/es/composite-comp/dito/config-panels/SearchBannerConfig/ConfigSetting/index.less +9 -0
- package/es/composite-comp/dito/config-panels/SearchBannerConfig/imgs/defaultImg.png +0 -0
- package/es/composite-comp/dito/config-panels/SearchBannerConfig/index.js +65 -0
- 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/SearchBannerSecondConfig/index.js +98 -0
- 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/composite-comp/nuri/components/AffiliateRecommend/mobile/index.js +1 -1
- package/es/composite-comp/nuri/components/AffiliateRecommend/mobile/index.less +15 -15
- package/es/composite-comp/public/components/Stores/mobile/index.less +3 -0
- package/es/constants/component-types.js +33 -9
- package/es/constants/index.js +44 -20
- package/es/constants/layout.js +46 -2
- package/es/core/Designer/ConfigPanel/index.js +18 -1
- package/es/core/Designer/index.js +2 -2
- package/es/core/Renderer/index.js +37 -2
- package/es/decorator/compositeDecorator.js +14 -4
- package/es/decorator/metaDecorator.js +1 -2
- package/es/locale/ar/ar.json +18 -1
- package/es/locale/en/en.json +18 -1
- package/es/locale/es/es.json +18 -1
- package/es/locale/mn/mn.json +4 -0
- 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/Montserrat-Bold.ttf +0 -0
- package/lib/assets/fonts/Montserrat-Medium.ttf +0 -0
- package/lib/assets/fonts/Montserrat-Regular.ttf +0 -0
- package/lib/assets/fonts/Montserrat-SemiBold.ttf +0 -0
- package/lib/assets/fonts/magic-box-iconfont.css +38 -6
- 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/base64/index.js +8 -2
- 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/ColorPickerInput/index.less +2 -0
- package/lib/common/CountDown/index.js +29 -2
- package/lib/common/CountDown/index.less +38 -5
- package/lib/common/ErrorBoundary/index.js +90 -0
- package/lib/common/FontStyles/index.less +1 -1
- 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 +32 -0
- package/lib/composite-comp/common/components/ImageLabel/index.js +2 -2
- package/lib/composite-comp/common/components/ImageLabel/index.less +23 -7
- package/lib/composite-comp/common/components/ProductItem/index.js +41 -24
- package/lib/composite-comp/common/components/ProductItem/index.less +17 -15
- package/lib/composite-comp/common/config-panels/BackgroundConfig/index.js +16 -12
- package/lib/composite-comp/common/config-panels/SpacingConfig/index.js +30 -0
- package/lib/composite-comp/dito/components/Bargain/defaultJSON.js +24 -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 +49 -11
- package/lib/composite-comp/dito/components/FlashDeal/mobile/index.js +15 -14
- package/lib/composite-comp/dito/components/FlashDeal/mobile/index.less +9 -1
- 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/defaultJSON.js +24 -0
- package/lib/composite-comp/dito/components/GroupBuy/mobile/index.js +8 -5
- 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 +75 -2
- package/lib/composite-comp/dito/components/PersonalInformation/mobile/images/avatar.png +0 -0
- package/lib/composite-comp/dito/components/PersonalInformation/mobile/index.js +159 -21
- package/lib/composite-comp/dito/components/PersonalInformation/mobile/index.less +108 -9
- package/lib/composite-comp/dito/components/Recommend/defaultJSON.js +55 -1
- package/lib/composite-comp/dito/components/Recommend/mobile/imgs/card.png +0 -0
- package/lib/composite-comp/dito/components/Recommend/mobile/index.js +177 -20
- package/lib/composite-comp/dito/components/Recommend/mobile/index.less +24 -1
- package/lib/composite-comp/dito/components/SearchBanner/defaultJSON.js +234 -0
- package/lib/composite-comp/dito/components/SearchBanner/imgs/defaultImg.png +0 -0
- package/lib/composite-comp/dito/components/SearchBanner/imgs/pcDefImg1.png +0 -0
- package/lib/composite-comp/dito/components/SearchBanner/index.js +108 -0
- package/lib/composite-comp/dito/components/SearchBanner/mobile/index.js +293 -0
- package/lib/composite-comp/dito/components/SearchBanner/mobile/index.less +108 -0
- 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/SignBoard/mobile/index.js +1 -1
- 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/BargainConfig/FlashDealConfigContent/index.js +7 -0
- package/lib/composite-comp/dito/config-panels/FlashDealConfig/FlashDealConfigContent/index.js +7 -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/GroupBuyConfig/GroupBuyConfigContent/index.js +7 -0
- 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/PersonalInformationConfig/ConfigDecoration/index.js +91 -0
- package/lib/composite-comp/dito/config-panels/PersonalInformationConfig/ConfigDecoration/index.less +9 -0
- 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 +23 -5
- package/lib/composite-comp/dito/config-panels/RecommendConfig/RecommendConfigContent/index.js +17 -1
- package/lib/composite-comp/dito/config-panels/RecommendConfig/index.js +10 -3
- package/lib/composite-comp/dito/config-panels/SearchBannerConfig/ConfigContent/index.js +197 -0
- package/lib/composite-comp/dito/config-panels/SearchBannerConfig/ConfigContent/index.less +7 -0
- package/lib/composite-comp/dito/config-panels/SearchBannerConfig/ConfigImageGroup/index.js +148 -0
- package/lib/composite-comp/dito/config-panels/SearchBannerConfig/ConfigImageGroup/index.less +0 -0
- package/lib/composite-comp/dito/config-panels/SearchBannerConfig/ConfigSetting/index.js +226 -0
- package/lib/composite-comp/dito/config-panels/SearchBannerConfig/ConfigSetting/index.less +9 -0
- package/lib/composite-comp/dito/config-panels/SearchBannerConfig/imgs/defaultImg.png +0 -0
- package/lib/composite-comp/dito/config-panels/SearchBannerConfig/index.js +65 -0
- 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/SearchBannerSecondConfig/index.js +98 -0
- 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/composite-comp/nuri/components/AffiliateRecommend/mobile/index.js +1 -1
- package/lib/composite-comp/nuri/components/AffiliateRecommend/mobile/index.less +15 -15
- package/lib/composite-comp/public/components/Stores/mobile/index.less +3 -0
- package/lib/constants/component-types.js +33 -9
- package/lib/constants/index.js +44 -20
- package/lib/constants/layout.js +46 -2
- package/lib/core/Designer/ConfigPanel/index.js +18 -1
- package/lib/core/Designer/index.js +2 -2
- package/lib/core/Renderer/index.js +37 -2
- package/lib/decorator/compositeDecorator.js +14 -4
- package/lib/decorator/metaDecorator.js +1 -2
- package/lib/locale/ar/ar.json +18 -1
- package/lib/locale/en/en.json +18 -1
- package/lib/locale/es/es.json +18 -1
- package/lib/locale/mn/mn.json +4 -0
- 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
|
@@ -3,19 +3,169 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.renderPreview = exports.parseUrl = exports.newParseUrl = exports.listToTree = exports.isPlatform = exports.getPromotionList = exports.computeStyle = exports.canNumber = void 0;
|
|
6
|
+
exports.renderPreview = exports.parseUrl = exports.newParseUrl = exports.listToTree = exports.isPlatform = exports.getTempCartCount = exports.getPromotionList = exports.getAdCoupon = exports.computeStyle = exports.canNumber = void 0;
|
|
7
7
|
|
|
8
8
|
var _qs = _interopRequireDefault(require("qs"));
|
|
9
9
|
|
|
10
10
|
var _pickBy = _interopRequireDefault(require("lodash/pickBy"));
|
|
11
11
|
|
|
12
|
+
var _messageUtil = require("./messageUtil");
|
|
13
|
+
|
|
12
14
|
var _commonUtil = require("./commonUtil");
|
|
13
15
|
|
|
16
|
+
var _storeUtil = require("./storeUtil");
|
|
17
|
+
|
|
18
|
+
var _locale = require("../locale");
|
|
19
|
+
|
|
14
20
|
var _constants = require("../constants");
|
|
15
21
|
|
|
16
22
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
17
23
|
|
|
24
|
+
var __awaiter = void 0 && (void 0).__awaiter || function (thisArg, _arguments, P, generator) {
|
|
25
|
+
function adopt(value) {
|
|
26
|
+
return value instanceof P ? value : new P(function (resolve) {
|
|
27
|
+
resolve(value);
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
32
|
+
function fulfilled(value) {
|
|
33
|
+
try {
|
|
34
|
+
step(generator.next(value));
|
|
35
|
+
} catch (e) {
|
|
36
|
+
reject(e);
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
function rejected(value) {
|
|
41
|
+
try {
|
|
42
|
+
step(generator["throw"](value));
|
|
43
|
+
} catch (e) {
|
|
44
|
+
reject(e);
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
function step(result) {
|
|
49
|
+
result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
53
|
+
});
|
|
54
|
+
};
|
|
55
|
+
|
|
56
|
+
var __generator = void 0 && (void 0).__generator || function (thisArg, body) {
|
|
57
|
+
var _ = {
|
|
58
|
+
label: 0,
|
|
59
|
+
sent: function sent() {
|
|
60
|
+
if (t[0] & 1) throw t[1];
|
|
61
|
+
return t[1];
|
|
62
|
+
},
|
|
63
|
+
trys: [],
|
|
64
|
+
ops: []
|
|
65
|
+
},
|
|
66
|
+
f,
|
|
67
|
+
y,
|
|
68
|
+
t,
|
|
69
|
+
g;
|
|
70
|
+
return g = {
|
|
71
|
+
next: verb(0),
|
|
72
|
+
"throw": verb(1),
|
|
73
|
+
"return": verb(2)
|
|
74
|
+
}, typeof Symbol === "function" && (g[Symbol.iterator] = function () {
|
|
75
|
+
return this;
|
|
76
|
+
}), g;
|
|
77
|
+
|
|
78
|
+
function verb(n) {
|
|
79
|
+
return function (v) {
|
|
80
|
+
return step([n, v]);
|
|
81
|
+
};
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
function step(op) {
|
|
85
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
86
|
+
|
|
87
|
+
while (_) {
|
|
88
|
+
try {
|
|
89
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
90
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
91
|
+
|
|
92
|
+
switch (op[0]) {
|
|
93
|
+
case 0:
|
|
94
|
+
case 1:
|
|
95
|
+
t = op;
|
|
96
|
+
break;
|
|
97
|
+
|
|
98
|
+
case 4:
|
|
99
|
+
_.label++;
|
|
100
|
+
return {
|
|
101
|
+
value: op[1],
|
|
102
|
+
done: false
|
|
103
|
+
};
|
|
104
|
+
|
|
105
|
+
case 5:
|
|
106
|
+
_.label++;
|
|
107
|
+
y = op[1];
|
|
108
|
+
op = [0];
|
|
109
|
+
continue;
|
|
110
|
+
|
|
111
|
+
case 7:
|
|
112
|
+
op = _.ops.pop();
|
|
113
|
+
|
|
114
|
+
_.trys.pop();
|
|
115
|
+
|
|
116
|
+
continue;
|
|
117
|
+
|
|
118
|
+
default:
|
|
119
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) {
|
|
120
|
+
_ = 0;
|
|
121
|
+
continue;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
if (op[0] === 3 && (!t || op[1] > t[0] && op[1] < t[3])) {
|
|
125
|
+
_.label = op[1];
|
|
126
|
+
break;
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
if (op[0] === 6 && _.label < t[1]) {
|
|
130
|
+
_.label = t[1];
|
|
131
|
+
t = op;
|
|
132
|
+
break;
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
if (t && _.label < t[2]) {
|
|
136
|
+
_.label = t[2];
|
|
137
|
+
|
|
138
|
+
_.ops.push(op);
|
|
139
|
+
|
|
140
|
+
break;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
if (t[2]) _.ops.pop();
|
|
144
|
+
|
|
145
|
+
_.trys.pop();
|
|
146
|
+
|
|
147
|
+
continue;
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
op = body.call(thisArg, _);
|
|
151
|
+
} catch (e) {
|
|
152
|
+
op = [6, e];
|
|
153
|
+
y = 0;
|
|
154
|
+
} finally {
|
|
155
|
+
f = t = 0;
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
if (op[0] & 5) throw op[1];
|
|
160
|
+
return {
|
|
161
|
+
value: op[0] ? op[1] : void 0,
|
|
162
|
+
done: true
|
|
163
|
+
};
|
|
164
|
+
}
|
|
165
|
+
};
|
|
18
166
|
/* eslint-disable import/no-cycle */
|
|
167
|
+
|
|
168
|
+
|
|
19
169
|
var isPlatform = function isPlatform() {
|
|
20
170
|
return window.magicDesign.partyType === 'P';
|
|
21
171
|
};
|
|
@@ -110,6 +260,17 @@ var newParseUrl = function newParseUrl(urlObj) {
|
|
|
110
260
|
}
|
|
111
261
|
};
|
|
112
262
|
break;
|
|
263
|
+
// 商品卡片列表
|
|
264
|
+
|
|
265
|
+
case _constants.urlTypeMap.CARD_PRODUCT_LIST:
|
|
266
|
+
params = {
|
|
267
|
+
action: 'operation',
|
|
268
|
+
params: {
|
|
269
|
+
type: 'CARD_PRODUCT_LIST',
|
|
270
|
+
offerIds: value
|
|
271
|
+
}
|
|
272
|
+
};
|
|
273
|
+
break;
|
|
113
274
|
|
|
114
275
|
case _constants.urlTypeMap.COUPONS:
|
|
115
276
|
// 领取优惠券
|
|
@@ -497,10 +658,55 @@ var parseUrl = function parseUrl(url) {
|
|
|
497
658
|
data: params
|
|
498
659
|
};
|
|
499
660
|
};
|
|
661
|
+
|
|
662
|
+
exports.parseUrl = parseUrl;
|
|
663
|
+
|
|
664
|
+
var getAdCoupon = function getAdCoupon(couponId) {
|
|
665
|
+
return __awaiter(void 0, void 0, void 0, function () {
|
|
666
|
+
var error_1;
|
|
667
|
+
return __generator(this, function (_a) {
|
|
668
|
+
switch (_a.label) {
|
|
669
|
+
case 0:
|
|
670
|
+
_a.trys.push([0, 2,, 3]);
|
|
671
|
+
|
|
672
|
+
return [4
|
|
673
|
+
/*yield*/
|
|
674
|
+
, (0, _commonUtil.commonFetch)('/designer/v1/h5/coupons/usercoupon', {
|
|
675
|
+
couponId: couponId
|
|
676
|
+
}, 'POST')];
|
|
677
|
+
|
|
678
|
+
case 1:
|
|
679
|
+
_a.sent();
|
|
680
|
+
|
|
681
|
+
_messageUtil.message.toast({
|
|
682
|
+
message: (0, _locale.i18n)('COLLECT_VOUCHER_SUCCESS'),
|
|
683
|
+
duration: 5000
|
|
684
|
+
});
|
|
685
|
+
|
|
686
|
+
window.sessionStorage.removeItem('adCouponId');
|
|
687
|
+
return [3
|
|
688
|
+
/*break*/
|
|
689
|
+
, 3];
|
|
690
|
+
|
|
691
|
+
case 2:
|
|
692
|
+
error_1 = _a.sent();
|
|
693
|
+
window.sessionStorage.setItem('adCouponId', couponId);
|
|
694
|
+
return [3
|
|
695
|
+
/*break*/
|
|
696
|
+
, 3];
|
|
697
|
+
|
|
698
|
+
case 3:
|
|
699
|
+
return [2
|
|
700
|
+
/*return*/
|
|
701
|
+
];
|
|
702
|
+
}
|
|
703
|
+
});
|
|
704
|
+
});
|
|
705
|
+
};
|
|
500
706
|
/** 刷新预览区域 */
|
|
501
707
|
|
|
502
708
|
|
|
503
|
-
exports.
|
|
709
|
+
exports.getAdCoupon = getAdCoupon;
|
|
504
710
|
|
|
505
711
|
var renderPreview = function renderPreview() {
|
|
506
712
|
var evt = new Event('render-view', {
|
|
@@ -616,5 +822,14 @@ var computeStyle = function computeStyle(_a, device) {
|
|
|
616
822
|
|
|
617
823
|
return wrapStyle;
|
|
618
824
|
};
|
|
825
|
+
/** 获取临时购物车 数量 */
|
|
826
|
+
|
|
827
|
+
|
|
828
|
+
exports.computeStyle = computeStyle;
|
|
829
|
+
|
|
830
|
+
var getTempCartCount = function getTempCartCount() {
|
|
831
|
+
var tempCarts = (0, _storeUtil.getStore)(_constants.STORE_KEY.TEMP_CART) || [];
|
|
832
|
+
return tempCarts.length;
|
|
833
|
+
};
|
|
619
834
|
|
|
620
|
-
exports.
|
|
835
|
+
exports.getTempCartCount = getTempCartCount;
|
package/lib/utils/commonUtil.js
CHANGED
|
@@ -3,11 +3,12 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.addZero = exports.addUrlQuery = void 0;
|
|
6
|
+
exports.addZero = exports.addUrlQuery = exports.JsonToUrl = void 0;
|
|
7
|
+
exports.afterLogOut = afterLogOut;
|
|
7
8
|
exports.asyncDataURLtoImage = asyncDataURLtoImage;
|
|
8
9
|
exports.checkLogin = exports.checkFileName = exports.calcLastTime = exports.asyncNextTick = void 0;
|
|
9
10
|
exports.commonFetch = commonFetch;
|
|
10
|
-
exports.convertCount = exports.compatibleNewPageData = void 0;
|
|
11
|
+
exports.convertCount = exports.compatibleNewPageData = exports.compareVersion = void 0;
|
|
11
12
|
exports.convertImageUrl = convertImageUrl;
|
|
12
13
|
exports.convertToRem = void 0;
|
|
13
14
|
exports.copy2ClipBoard = copy2ClipBoard;
|
|
@@ -20,6 +21,7 @@ exports.getUrlParams = void 0;
|
|
|
20
21
|
exports.goLogin = goLogin;
|
|
21
22
|
exports.importAsync = void 0;
|
|
22
23
|
exports.isLogin = isLogin;
|
|
24
|
+
exports.jumpUrlConfig = void 0;
|
|
23
25
|
exports.navigateBack = navigateBack;
|
|
24
26
|
exports.onListenTouch = exports.nextTick = exports.needReverse = exports.navigateTo = void 0;
|
|
25
27
|
exports.pushGA = pushGA;
|
|
@@ -30,6 +32,7 @@ exports.shareTwitter = shareTwitter;
|
|
|
30
32
|
exports.sleep = sleep;
|
|
31
33
|
exports.styleStringify = void 0;
|
|
32
34
|
exports.triggerBuryingPointEvent = triggerBuryingPointEvent;
|
|
35
|
+
exports.xssDecode = void 0;
|
|
33
36
|
|
|
34
37
|
var _axios = _interopRequireDefault(require("axios"));
|
|
35
38
|
|
|
@@ -43,6 +46,10 @@ var _androidUtil = require("./androidUtil");
|
|
|
43
46
|
|
|
44
47
|
var _storeUtil = require("./storeUtil");
|
|
45
48
|
|
|
49
|
+
var _businessUtil = require("./businessUtil");
|
|
50
|
+
|
|
51
|
+
var _coreUtil = require("./coreUtil");
|
|
52
|
+
|
|
46
53
|
var _constants = require("../constants");
|
|
47
54
|
|
|
48
55
|
var _mobx = require("../mobx");
|
|
@@ -251,7 +258,8 @@ function commonFetch(url, data, method) {
|
|
|
251
258
|
'Content-Type': 'application/json; charset=UTF-8',
|
|
252
259
|
credentials: credentials,
|
|
253
260
|
accessToken: credentials,
|
|
254
|
-
'X-CSRF-TOKEN': csrf
|
|
261
|
+
'X-CSRF-TOKEN': csrf,
|
|
262
|
+
'Device-Type': (0, _coreUtil.isPc)() ? 'pc' : 'web'
|
|
255
263
|
};
|
|
256
264
|
|
|
257
265
|
if (url.endsWith('portal/login')) {
|
|
@@ -366,6 +374,21 @@ function navigateBack(depth) {
|
|
|
366
374
|
|
|
367
375
|
function isLogin() {
|
|
368
376
|
return localStorage.getItem('isLogin') === 'Y';
|
|
377
|
+
} // export function removeCookie(key) {
|
|
378
|
+
// return Cookies.remove(key);
|
|
379
|
+
// }
|
|
380
|
+
|
|
381
|
+
|
|
382
|
+
function afterLogOut() {
|
|
383
|
+
// removeCookie('eshopByPcIsLogin', 'Y');
|
|
384
|
+
localStorage.removeItem('isLogin');
|
|
385
|
+
localStorage.removeItem('currentUser');
|
|
386
|
+
localStorage.removeItem('h5Token');
|
|
387
|
+
localStorage.removeItem('accountPageValue');
|
|
388
|
+
localStorage.removeItem('isGiveCoupon');
|
|
389
|
+
sessionStorage.removeItem('channelPurchase');
|
|
390
|
+
|
|
391
|
+
_mobx.userState.clearUserState();
|
|
369
392
|
}
|
|
370
393
|
/**
|
|
371
394
|
* 跳转登陆页面
|
|
@@ -395,6 +418,10 @@ function goLogin(state, replaceFlag) {
|
|
|
395
418
|
navigateTo(signUrl, state);
|
|
396
419
|
}
|
|
397
420
|
}
|
|
421
|
+
|
|
422
|
+
var xssDecode = function xssDecode(html) {
|
|
423
|
+
return html.replace(/</g, '<').replace(/>/g, '>');
|
|
424
|
+
};
|
|
398
425
|
/**
|
|
399
426
|
* 检查是否登录 未登录返回登录页
|
|
400
427
|
* @param {boolean?} isLead 是否引导登录
|
|
@@ -402,6 +429,8 @@ function goLogin(state, replaceFlag) {
|
|
|
402
429
|
*/
|
|
403
430
|
|
|
404
431
|
|
|
432
|
+
exports.xssDecode = xssDecode;
|
|
433
|
+
|
|
405
434
|
var checkLogin = function checkLogin(isLead, redirectUrl, replaceFlag) {
|
|
406
435
|
if (isLead === void 0) {
|
|
407
436
|
isLead = true;
|
|
@@ -531,13 +560,113 @@ var reverseStrArr = function reverseStrArr(arr) {
|
|
|
531
560
|
|
|
532
561
|
return arr.join(' ').replace(' +', '+').replace(' :', ':');
|
|
533
562
|
};
|
|
563
|
+
|
|
564
|
+
exports.reverseStrArr = reverseStrArr;
|
|
565
|
+
|
|
566
|
+
var JsonToUrl = function JsonToUrl(data) {
|
|
567
|
+
var tempArr = [];
|
|
568
|
+
|
|
569
|
+
for (var i in data) {
|
|
570
|
+
var keyData = encodeURIComponent(i);
|
|
571
|
+
var value = encodeURIComponent(data[i]) === 'null' ? '' : encodeURIComponent(data[i]);
|
|
572
|
+
tempArr.push(keyData + "=" + value);
|
|
573
|
+
}
|
|
574
|
+
|
|
575
|
+
var urlParamsStr = tempArr.join('&');
|
|
576
|
+
return urlParamsStr;
|
|
577
|
+
};
|
|
578
|
+
|
|
579
|
+
exports.JsonToUrl = JsonToUrl;
|
|
580
|
+
|
|
581
|
+
var jumpUrlConfig = function jumpUrlConfig(item) {
|
|
582
|
+
var _a, _b, _c;
|
|
583
|
+
|
|
584
|
+
var _d = item || {},
|
|
585
|
+
objType = _d.objType,
|
|
586
|
+
objValue = _d.objValue;
|
|
587
|
+
|
|
588
|
+
var jumpUrl = '';
|
|
589
|
+
|
|
590
|
+
switch (objType) {
|
|
591
|
+
// 新增case
|
|
592
|
+
case 'ProductList':
|
|
593
|
+
{
|
|
594
|
+
var offerIdList = objValue.filteredProductsRela.offerIdList;
|
|
595
|
+
jumpUrl = "/product/list?from=home&objType=ProductList&offerIdList=" + offerIdList;
|
|
596
|
+
break;
|
|
597
|
+
}
|
|
598
|
+
|
|
599
|
+
case 'Category':
|
|
600
|
+
jumpUrl = (0, _coreUtil.isPc)() ? "/product/list?from=home&objType=Category&catgIds=" + objValue.objId : "/product/list/" + objValue.objId;
|
|
601
|
+
break;
|
|
602
|
+
|
|
603
|
+
case 'StoreCategory':
|
|
604
|
+
jumpUrl = (0, _coreUtil.isPc)() ? "/product/list?from=home&objType=Category&catgIds=" + objValue.objId + "&storeCatgIds=" + objValue.objId : "/product/list/" + objValue.objId + "?storeCatgIds=" + objValue.objId;
|
|
605
|
+
break;
|
|
606
|
+
|
|
607
|
+
case 'Coupons':
|
|
608
|
+
(0, _businessUtil.getAdCoupon)(objValue.objId);
|
|
609
|
+
return;
|
|
610
|
+
|
|
611
|
+
case 'ProductDetail':
|
|
612
|
+
{
|
|
613
|
+
var offerId = objValue.objId && objValue.objId.split(',')[0];
|
|
614
|
+
var productId = objValue.objId && objValue.objId.split(',')[1];
|
|
615
|
+
jumpUrl = "/product/detail/" + offerId + "?productId=" + productId;
|
|
616
|
+
break;
|
|
617
|
+
}
|
|
618
|
+
|
|
619
|
+
case 'ProductDetailPage':
|
|
620
|
+
{
|
|
621
|
+
var offerId = objValue.objId && objValue.objId.split(',')[0];
|
|
622
|
+
var productId = objValue.objId && objValue.objId.split(',')[1];
|
|
623
|
+
jumpUrl = "/product/detail/" + offerId + "?productId=" + productId;
|
|
624
|
+
break;
|
|
625
|
+
}
|
|
626
|
+
|
|
627
|
+
case 'FilteredProducts':
|
|
628
|
+
{
|
|
629
|
+
var params = JsonToUrl(objValue.filteredProductsRela);
|
|
630
|
+
params = params.replace('productName', 'q').replace('cmpTypeId', 'campaignType');
|
|
631
|
+
jumpUrl = (0, _coreUtil.isPc)() ? "/product/list?from=home&objType=FilteredProducts&" + params : "/product/list/null?" + params;
|
|
632
|
+
break;
|
|
633
|
+
}
|
|
634
|
+
|
|
635
|
+
case 'FunctionPage':
|
|
636
|
+
{
|
|
637
|
+
var url = objValue.objId && objValue.objId.split(',')[1];
|
|
638
|
+
jumpUrl = "" + url;
|
|
639
|
+
break;
|
|
640
|
+
}
|
|
641
|
+
|
|
642
|
+
case 'CustomizedPage':
|
|
643
|
+
jumpUrl = "/poster/" + objValue.objId;
|
|
644
|
+
break;
|
|
645
|
+
|
|
646
|
+
case 'URL':
|
|
647
|
+
{
|
|
648
|
+
if (((_a = objValue.urlRelaDto) === null || _a === void 0 ? void 0 : _a.openMode) === 'new') {
|
|
649
|
+
window.open(objValue.urlRelaDto.url);
|
|
650
|
+
} else {
|
|
651
|
+
window.location.href = (_c = (_b = objValue === null || objValue === void 0 ? void 0 : objValue.urlRelaDto) === null || _b === void 0 ? void 0 : _b.url) !== null && _c !== void 0 ? _c : objValue.url;
|
|
652
|
+
}
|
|
653
|
+
|
|
654
|
+
return;
|
|
655
|
+
}
|
|
656
|
+
|
|
657
|
+
default:
|
|
658
|
+
break;
|
|
659
|
+
}
|
|
660
|
+
|
|
661
|
+
(0, _coreUtil.clickUrl)(jumpUrl);
|
|
662
|
+
};
|
|
534
663
|
/**
|
|
535
664
|
* 补0 函数
|
|
536
665
|
* @param {*} num 数字
|
|
537
666
|
*/
|
|
538
667
|
|
|
539
668
|
|
|
540
|
-
exports.
|
|
669
|
+
exports.jumpUrlConfig = jumpUrlConfig;
|
|
541
670
|
|
|
542
671
|
var addZero = function addZero(num) {
|
|
543
672
|
return String(num).length === 1 ? "0" + String(num) : String(num);
|
|
@@ -600,9 +729,31 @@ function convertImageUrl(imageObj, type) {
|
|
|
600
729
|
return encodeURI(imageObj[typeMap] || imageObj.url);
|
|
601
730
|
}, '');
|
|
602
731
|
}
|
|
732
|
+
|
|
733
|
+
var compareVersion = function compareVersion(v1, v2) {
|
|
734
|
+
// 将两个版本号拆成数组
|
|
735
|
+
var arr1 = v1.split('.');
|
|
736
|
+
var arr2 = v2.split('.');
|
|
737
|
+
var minLength = Math.min(arr1.length, arr2.length); // 依次比较版本号每一位大小
|
|
738
|
+
|
|
739
|
+
for (var i = 0; i < minLength; i += 1) {
|
|
740
|
+
if (parseInt(arr1[i], 10) !== parseInt(arr2[i], 10)) {
|
|
741
|
+
return parseInt(arr1[i], 10) > parseInt(arr2[i], 10) ? 1 : -1;
|
|
742
|
+
}
|
|
743
|
+
} // 若前几位分隔相同,则按分隔数比较。
|
|
744
|
+
|
|
745
|
+
|
|
746
|
+
if (arr1.length === arr2.length) {
|
|
747
|
+
return 0;
|
|
748
|
+
}
|
|
749
|
+
|
|
750
|
+
return arr1.length > arr2.length ? 1 : -1;
|
|
751
|
+
};
|
|
603
752
|
/** 序列化 style对象 */
|
|
604
753
|
|
|
605
754
|
|
|
755
|
+
exports.compareVersion = compareVersion;
|
|
756
|
+
|
|
606
757
|
var styleStringify = function styleStringify(style, _a) {
|
|
607
758
|
var _b = (_a === void 0 ? {} : _a).suffix,
|
|
608
759
|
suffix = _b === void 0 ? 'px' : _b;
|
package/lib/utils/coreUtil.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.setMagicDesign = exports.renderPreview = exports.isPc = exports.isDesignMode = exports.isAutoAudit = exports.isActiveFloor = exports.getVideoCover = exports.copyNode = exports.clickUrl = void 0;
|
|
6
|
+
exports.setMagicDesign = exports.renderPreview = exports.isPc = exports.isDesignMode = exports.isAutoAudit = exports.isActiveFloor = exports.getVideoCover = exports.createProdCardModal = exports.copyNode = exports.clickUrl = void 0;
|
|
7
7
|
|
|
8
8
|
var _uuid = require("uuid");
|
|
9
9
|
|
|
@@ -21,6 +21,8 @@ var _locale = require("../locale");
|
|
|
21
21
|
|
|
22
22
|
var _Video = require("../common/Video");
|
|
23
23
|
|
|
24
|
+
var _mobx = require("../mobx");
|
|
25
|
+
|
|
24
26
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
25
27
|
|
|
26
28
|
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); }
|
|
@@ -302,6 +304,51 @@ function isUrl(string) {
|
|
|
302
304
|
}
|
|
303
305
|
}
|
|
304
306
|
|
|
307
|
+
var createProdCardModal = function createProdCardModal(ids) {
|
|
308
|
+
return __awaiter(void 0, void 0, void 0, function () {
|
|
309
|
+
var res, resList;
|
|
310
|
+
|
|
311
|
+
var _a;
|
|
312
|
+
|
|
313
|
+
return __generator(this, function (_b) {
|
|
314
|
+
switch (_b.label) {
|
|
315
|
+
case 0:
|
|
316
|
+
if (ids.length === 0) return [2
|
|
317
|
+
/*return*/
|
|
318
|
+
];
|
|
319
|
+
return [4
|
|
320
|
+
/*yield*/
|
|
321
|
+
, (0, _commonUtil.commonFetch)('/designer/v1/h5/offers', {
|
|
322
|
+
pageIndex: 1,
|
|
323
|
+
pageSize: 20,
|
|
324
|
+
offerIdList: ids || []
|
|
325
|
+
}, 'POST')];
|
|
326
|
+
|
|
327
|
+
case 1:
|
|
328
|
+
res = _b.sent();
|
|
329
|
+
resList = ((_a = res.pageInfo) === null || _a === void 0 ? void 0 : _a.list) || [];
|
|
330
|
+
if (resList.length === 0) return [2
|
|
331
|
+
/*return*/
|
|
332
|
+
];
|
|
333
|
+
document.body.classList.add('no-scroll');
|
|
334
|
+
|
|
335
|
+
_mobx.frameStore.setState({
|
|
336
|
+
pcProdCardModalState: {
|
|
337
|
+
visible: true,
|
|
338
|
+
data: resList
|
|
339
|
+
}
|
|
340
|
+
});
|
|
341
|
+
|
|
342
|
+
return [2
|
|
343
|
+
/*return*/
|
|
344
|
+
];
|
|
345
|
+
}
|
|
346
|
+
});
|
|
347
|
+
});
|
|
348
|
+
};
|
|
349
|
+
|
|
350
|
+
exports.createProdCardModal = createProdCardModal;
|
|
351
|
+
|
|
305
352
|
var clickUrl = function clickUrl(url, state) {
|
|
306
353
|
var _a, _b;
|
|
307
354
|
|
|
@@ -320,11 +367,15 @@ var clickUrl = function clickUrl(url, state) {
|
|
|
320
367
|
data = _c.data;
|
|
321
368
|
|
|
322
369
|
var _d = data.params,
|
|
323
|
-
params = _d === void 0 ? {} : _d; //
|
|
324
|
-
// console.log({ type: 'jumpBrowser', params: { url: params.link } });
|
|
370
|
+
params = _d === void 0 ? {} : _d; // PC商品卡片弹窗
|
|
325
371
|
|
|
372
|
+
if (params.type === 'CARD_PRODUCT_LIST') {
|
|
373
|
+
createProdCardModal(params.offerIds);
|
|
374
|
+
return;
|
|
375
|
+
}
|
|
326
376
|
/** 锚点跳转 */
|
|
327
377
|
|
|
378
|
+
|
|
328
379
|
if (params.type === 'ANCHOR') {
|
|
329
380
|
(0, _commonUtil.ensure)(function () {
|
|
330
381
|
var nodeId = isPc() ? params.data.pcNodeId : params.data.mobileNodeId;
|
|
@@ -420,7 +471,11 @@ var clickUrl = function clickUrl(url, state) {
|
|
|
420
471
|
window.open(link);
|
|
421
472
|
}
|
|
422
473
|
} else {
|
|
423
|
-
(
|
|
474
|
+
if (isPc()) {
|
|
475
|
+
window.location.href += "web" + link;
|
|
476
|
+
} else {
|
|
477
|
+
(0, _commonUtil.navigateTo)(link, state);
|
|
478
|
+
}
|
|
424
479
|
}
|
|
425
480
|
} else {
|
|
426
481
|
(0, _commonUtil.navigateTo)(link, state);
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.message = void 0;
|
|
7
|
+
exports.toast = toast;
|
|
8
|
+
|
|
9
|
+
var _mobx = require("../mobx");
|
|
10
|
+
|
|
11
|
+
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); }
|
|
12
|
+
|
|
13
|
+
function toast(config) {
|
|
14
|
+
var defaults = {
|
|
15
|
+
message: 'success',
|
|
16
|
+
duration: 3000,
|
|
17
|
+
onClose: function onClose() {},
|
|
18
|
+
visible: true
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
var _a = _extends(defaults, config),
|
|
22
|
+
message = _a.message,
|
|
23
|
+
duration = _a.duration,
|
|
24
|
+
onClose = _a.onClose,
|
|
25
|
+
visible = _a.visible;
|
|
26
|
+
|
|
27
|
+
_mobx.frameStore.setState({
|
|
28
|
+
toastState: {
|
|
29
|
+
message: message,
|
|
30
|
+
duration: duration,
|
|
31
|
+
onClose: onClose,
|
|
32
|
+
visible: visible
|
|
33
|
+
}
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
var message = {
|
|
38
|
+
toast: toast
|
|
39
|
+
};
|
|
40
|
+
exports.message = message;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fonixtree/magic-design",
|
|
3
3
|
"author": "Cylon Team",
|
|
4
|
-
"version": "2.0.
|
|
4
|
+
"version": "2.0.203",
|
|
5
5
|
"description": "Magic Design",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"module": "es/index.js",
|
|
@@ -25,6 +25,8 @@
|
|
|
25
25
|
"antd": "4.24.8",
|
|
26
26
|
"antd4": "npm:antd@4.24.8",
|
|
27
27
|
"axios": "0.27.2",
|
|
28
|
+
"framer-motion": "6.x",
|
|
29
|
+
"html2canvas": "^1.4.1",
|
|
28
30
|
"immutability-helper": "3.1.1",
|
|
29
31
|
"interactjs": "1.10.17",
|
|
30
32
|
"lodash": "4.17.21",
|
|
@@ -32,7 +34,8 @@
|
|
|
32
34
|
"marked": "4.3.0",
|
|
33
35
|
"mobx": "6.6.1",
|
|
34
36
|
"mobx-react": "7.5.2",
|
|
35
|
-
"moment": "2.
|
|
37
|
+
"moment": "2.29.3",
|
|
38
|
+
"motion": "^10.12.18",
|
|
36
39
|
"postcss-pxtorem": "^6.0.0",
|
|
37
40
|
"quill": "^1.3.7",
|
|
38
41
|
"ramda": "^0.28.0",
|
|
Binary file
|
|
Binary file
|
|
Binary file
|