@fonixtree/magic-design 0.1.78 → 0.1.80
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/Trueno-Light.otf +0 -0
- package/es/assets/fonts/Trueno-Regular.otf +0 -0
- package/es/assets/fonts/TruenoBd.otf +0 -0
- package/es/assets/fonts/magic-box-iconfont.css +31 -3
- package/es/assets/fonts/magic-box-iconfont.css.bak +31 -3
- package/es/assets/fonts/magic-box-iconfont.js +1 -1
- package/es/assets/fonts/magic-box-iconfont.js.bak +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 +36 -2
- package/es/assets/images/layout-icon/walletLayout2.png +0 -0
- package/es/assets/images/layout-icon/walletNuriLayout1.png +0 -0
- package/es/assets/less/cylon-antd.less +7246 -1686
- package/es/assets/less/font.less +22 -0
- package/es/common/AffiliateProductModal/index.js +582 -0
- package/es/common/AffiliateProductModal/index.less +146 -0
- package/es/common/CardCarousel/index.js +171 -0
- package/es/common/CardCarousel/index.less +28 -0
- package/es/common/GroupList/index.less +3 -0
- package/es/common/ImagePicker/index.js +1 -3
- package/es/common/LinkModal/FilteredProductModal/index.js +1 -1
- package/es/common/LinkModal/FunctionTable/index.js +2 -1
- package/es/common/LinkModal/index.js +14 -2
- package/es/common/MyModal/index.js +417 -0
- package/es/common/MyModal/index.less +74 -0
- package/es/common/ProductModal/index.js +2 -3
- package/es/common/ProductSource/index.js +42 -10
- package/es/common/UrlPicker/index.js +3 -1
- package/es/common/index.js +16 -0
- package/es/composite-comp/bol/components/Banner/mobile/index.js +4 -1
- package/es/composite-comp/bol/components/ImageText/pc/index.js +2 -2
- package/es/composite-comp/bol/components/Video/index.js +1 -2
- package/es/composite-comp/bol/components/Wallet/defaultJSON.js +112 -88
- package/es/composite-comp/bol/components/Wallet/index.js +11 -15
- package/es/composite-comp/bol/components/Wallet/mobile/index.js +314 -64
- package/es/composite-comp/bol/components/Wallet/mobile/index.less +89 -13
- package/es/composite-comp/bol/components/Wallet/pc/index.js +0 -2
- package/es/composite-comp/bol/components/Wallet/pc/index.less +1 -40
- package/es/composite-comp/bol/components/WalletNuri/defaultJSON.js +148 -0
- package/es/composite-comp/bol/components/WalletNuri/index.js +84 -0
- package/es/composite-comp/bol/components/WalletNuri/mobile/index.js +366 -0
- package/es/composite-comp/bol/components/WalletNuri/mobile/index.less +22 -0
- package/es/composite-comp/bol/config-panels/WalletConfig/WalletConfigImageGroup/index.js +1 -6
- package/es/composite-comp/bol/config-panels/WalletConfig/WalletConfigSetting/index.js +201 -0
- package/es/composite-comp/bol/config-panels/WalletConfig/WalletConfigSetting/index.less +9 -0
- package/es/composite-comp/bol/config-panels/WalletConfig/index.js +11 -2
- package/es/composite-comp/bol/config-panels/WalletNuriConfig/GroupList/defaultImg.png +0 -0
- package/es/composite-comp/bol/config-panels/WalletNuriConfig/GroupList/index.js +100 -0
- package/es/composite-comp/bol/config-panels/WalletNuriConfig/GroupList/index.less +72 -0
- package/es/composite-comp/bol/config-panels/WalletNuriConfig/WalletNuriConfigImageGroup/index.js +123 -0
- package/es/composite-comp/bol/config-panels/WalletNuriConfig/WalletNuriConfigImageGroup/index.less +0 -0
- package/es/composite-comp/bol/config-panels/WalletNuriConfig/imgs/defaultImg.png +0 -0
- package/es/composite-comp/bol/config-panels/WalletNuriConfig/index.js +61 -0
- package/es/composite-comp/bol/second-config-panels/ImageTextSecondConfig/index.js +8 -6
- package/es/composite-comp/bol/second-config-panels/WalletNuriSecondConfig/index.js +152 -0
- package/es/composite-comp/bol/second-config-panels/WalletSecondConfig/index.js +58 -82
- package/es/composite-comp/bol/second-config-panels/WalletSecondConfig/index.less +2 -0
- package/es/composite-comp/common/components/AffiliateProductItem/imgs/icon-Balance2.svg +9 -0
- package/es/composite-comp/common/components/AffiliateProductItem/imgs/icon-Koin.svg +40 -0
- package/es/composite-comp/common/components/AffiliateProductItem/index.js +177 -0
- package/es/composite-comp/common/components/AffiliateProductItem/index.less +129 -0
- package/es/composite-comp/common/components/ImageLabel/index.less +9 -3
- package/es/composite-comp/common/components/ProductItem/index.js +25 -17
- package/es/composite-comp/common/components/ProductItem/index.less +17 -8
- package/es/composite-comp/common/config-panels/CustomizeConfig/index.js +13 -0
- package/es/composite-comp/common/config-panels/CustomizeConfig/index.less +3 -2
- package/es/composite-comp/dito/components/AffiliateRecommend/defaultJSON.js +243 -0
- package/es/composite-comp/dito/components/AffiliateRecommend/index.js +90 -0
- package/es/composite-comp/dito/components/AffiliateRecommend/mobile/index.js +660 -0
- package/es/composite-comp/dito/components/AffiliateRecommend/mobile/index.less +84 -0
- package/es/composite-comp/dito/components/AffiliateRecommend/pc/index.js +728 -0
- package/es/composite-comp/dito/components/AffiliateRecommend/pc/index.less +124 -0
- package/es/composite-comp/dito/components/FlashDeal/mobile/index.js +8 -6
- package/es/composite-comp/dito/components/FlashDeal/pc/index.js +8 -6
- package/es/composite-comp/dito/components/HeadNavigation/defaultJSON.js +97 -0
- package/es/composite-comp/dito/components/HeadNavigation/index.js +84 -0
- package/es/composite-comp/dito/components/HeadNavigation/mobile/index.js +112 -0
- package/es/composite-comp/dito/components/HeadNavigation/mobile/index.less +34 -0
- package/es/composite-comp/dito/components/MenuNavigation/MenuNavMetaImage/index.js +206 -0
- package/es/composite-comp/dito/components/MenuNavigation/MenuNavMetaImage/index.less +25 -0
- package/es/composite-comp/dito/components/MenuNavigation/defaultJSON.js +107 -0
- package/es/composite-comp/dito/components/MenuNavigation/index.js +84 -0
- package/es/composite-comp/dito/components/MenuNavigation/mobile/index.js +87 -0
- package/es/composite-comp/dito/components/MenuNavigation/mobile/index.less +8 -0
- package/es/composite-comp/dito/components/Recommend/mobile/index.js +10 -9
- package/es/composite-comp/dito/components/Recommend/pc/index.js +12 -11
- package/es/composite-comp/dito/components/SearchBar/mobile/index.js +1 -1
- package/es/composite-comp/dito/config-panels/AffiliateRecommendConfig/RecommendConfigContent/index.js +102 -0
- package/es/composite-comp/dito/config-panels/AffiliateRecommendConfig/RecommendConfigContent/index.less +0 -0
- package/es/composite-comp/dito/config-panels/AffiliateRecommendConfig/RecommendConfigGroup/index.js +148 -0
- package/es/composite-comp/dito/config-panels/AffiliateRecommendConfig/RecommendConfigGroup/index.less +16 -0
- package/es/composite-comp/dito/config-panels/AffiliateRecommendConfig/imgs/defaultImg.png +0 -0
- package/es/composite-comp/dito/config-panels/AffiliateRecommendConfig/index.js +141 -0
- package/es/composite-comp/dito/config-panels/HeadNavigationConfig/GroupList/index.js +203 -0
- package/es/composite-comp/dito/config-panels/HeadNavigationConfig/GroupList/index.less +72 -0
- package/es/composite-comp/dito/config-panels/HeadNavigationConfig/HeadNavConfigImageGroup/index.js +142 -0
- package/es/composite-comp/dito/config-panels/HeadNavigationConfig/index.js +123 -0
- package/es/composite-comp/dito/config-panels/HeadNavigationConfig/index.less +23 -0
- package/es/composite-comp/dito/config-panels/MenuNavigationConfig/GroupList/index.js +203 -0
- package/es/composite-comp/dito/config-panels/MenuNavigationConfig/GroupList/index.less +72 -0
- package/es/composite-comp/dito/config-panels/MenuNavigationConfig/MenuNavConfigImageGroup/index.js +137 -0
- package/es/composite-comp/dito/config-panels/MenuNavigationConfig/MenuNavConfigImageGroup/index.less +6 -0
- package/es/composite-comp/dito/config-panels/MenuNavigationConfig/index.js +40 -0
- package/es/composite-comp/dito/config-panels/RecommendConfig/RecommendConfigGroup/index.js +15 -11
- package/es/composite-comp/dito/second-config-panels/AffiliateRecommendSecondConfig/AIRecommendation/index.js +431 -0
- package/es/composite-comp/dito/second-config-panels/AffiliateRecommendSecondConfig/index.js +214 -0
- package/es/composite-comp/dito/second-config-panels/AffiliateRecommendSecondConfig/index.less +15 -0
- package/es/composite-comp/dito/second-config-panels/HeadNavigationSecondConfig/index.js +127 -0
- package/es/composite-comp/dito/second-config-panels/MenuNavigationSecondConfig/index.js +127 -0
- package/es/constants/component-types.js +27 -3
- package/es/constants/index.js +26 -1
- package/es/constants/layout.js +48 -1
- package/es/core/Designer/ChatRobot/components/SearchCondition/index.js +110 -0
- package/es/core/Designer/ChatRobot/components/SearchCondition/index.less +33 -0
- package/es/core/Designer/ChatRobot/index.js +36 -14
- package/es/core/Designer/ChatRobot/index.less +69 -28
- package/es/core/Designer/ConfigPanel/index.js +8 -3
- package/es/core/Designer/History/index.js +2 -2
- package/es/core/Designer/PageCompList/index.js +8 -5
- package/es/core/Designer/QuickMenuBar/index.js +5 -3
- package/es/core/Designer/QuickMenuBar/index.less +4 -0
- package/es/core/Designer/RenderHtml/index.js +18 -15
- package/es/core/Designer/RenderHtml/index.less +1 -1
- package/es/core/Designer/ToolBarModal/ToolBtn/components/AlignPicker/images/AlignCenterSVG.js +19 -6
- package/es/core/Designer/ToolBarModal/ToolBtn/components/AlignPicker/images/AlignLeftSVG.js +19 -6
- package/es/core/Designer/ToolBarModal/ToolBtn/components/AlignPicker/images/AlignRightSVG.js +19 -6
- package/es/core/Designer/ToolBarModal/ToolBtn/components/BulletPicker/index.js +27 -6
- package/es/core/Designer/ToolBarModal/ToolBtn/components/BulletPicker/index.less +4 -20
- package/es/core/Designer/ToolBarModal/ToolBtn/components/ColorPickerBtn/UnderlineSelectPicker/index.js +77 -0
- package/es/core/Designer/ToolBarModal/ToolBtn/components/ColorPickerBtn/UnderlineSelectPicker/index.less +27 -0
- package/es/core/Designer/ToolBarModal/ToolBtn/components/ColorPickerBtn/index.js +36 -5
- package/es/core/Designer/ToolBarModal/ToolBtn/components/ColorPickerBtn/index.less +17 -16
- package/es/core/Designer/ToolBarModal/ToolBtn/components/OrderedPicker/index.js +27 -6
- package/es/core/Designer/ToolBarModal/ToolBtn/components/OrderedPicker/index.less +4 -20
- package/es/core/Designer/ToolBarModal/ToolBtn/images/AlignCenterSVG.js +40 -0
- package/es/core/Designer/ToolBarModal/ToolBtn/images/AlignLeftSVG.js +40 -0
- package/es/core/Designer/ToolBarModal/ToolBtn/images/AlignRightSVG.js +40 -0
- package/es/core/Designer/ToolBarModal/ToolBtn/index.js +28 -3
- package/es/core/Designer/ToolBarModal/ToolBtn/index.less +2 -1
- package/es/core/Designer/ToolBarModal/index.js +68 -22
- package/es/core/Designer/ToolBarModal/index.less +3 -2
- package/es/core/Designer/index.js +12 -1
- package/es/core/Renderer/index.js +55 -8
- package/es/decorator/compositeDecorator.js +23 -0
- package/es/locale/en/en.json +6 -1
- package/es/locale/es/es.json +6 -1
- package/es/locale/id/id.json +6 -1
- package/es/meta-comp/components/Image/index.js +31 -25
- package/es/meta-comp/components/Text/formats/textAlign.js +58 -0
- package/es/meta-comp/components/Text/index.js +20 -1
- package/es/meta-comp/components/Text/index.less +8 -0
- package/es/meta-comp/config-panels/ButtonConfig/index.js +5 -5
- package/es/meta-comp/config-panels/ImageConfig/index.js +48 -44
- package/es/mobx/Frame.js +17 -2
- package/es/utils/businessUtil.js +17 -6
- package/es/utils/commonUtil.js +54 -4
- package/es/utils/currencyUtil.js +9 -2
- package/lib/assets/fonts/Trueno-Light.otf +0 -0
- package/lib/assets/fonts/Trueno-Regular.otf +0 -0
- package/lib/assets/fonts/TruenoBd.otf +0 -0
- package/lib/assets/fonts/magic-box-iconfont.css +31 -3
- package/lib/assets/fonts/magic-box-iconfont.css.bak +31 -3
- package/lib/assets/fonts/magic-box-iconfont.js +1 -1
- package/lib/assets/fonts/magic-box-iconfont.js.bak +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 +36 -2
- package/lib/assets/images/layout-icon/walletLayout2.png +0 -0
- package/lib/assets/images/layout-icon/walletNuriLayout1.png +0 -0
- package/lib/assets/less/cylon-antd.less +7246 -1686
- package/lib/assets/less/font.less +22 -0
- package/lib/common/AffiliateProductModal/index.js +582 -0
- package/lib/common/AffiliateProductModal/index.less +146 -0
- package/lib/common/CardCarousel/index.js +171 -0
- package/lib/common/CardCarousel/index.less +28 -0
- package/lib/common/GroupList/index.less +3 -0
- package/lib/common/ImagePicker/index.js +1 -3
- package/lib/common/LinkModal/FilteredProductModal/index.js +1 -1
- package/lib/common/LinkModal/FunctionTable/index.js +2 -1
- package/lib/common/LinkModal/index.js +14 -2
- package/lib/common/MyModal/index.js +417 -0
- package/lib/common/MyModal/index.less +74 -0
- package/lib/common/ProductModal/index.js +2 -3
- package/lib/common/ProductSource/index.js +42 -10
- package/lib/common/UrlPicker/index.js +3 -1
- package/lib/common/index.js +16 -0
- package/lib/composite-comp/bol/components/Banner/mobile/index.js +4 -1
- package/lib/composite-comp/bol/components/ImageText/pc/index.js +2 -2
- package/lib/composite-comp/bol/components/Video/index.js +1 -2
- package/lib/composite-comp/bol/components/Wallet/defaultJSON.js +112 -88
- package/lib/composite-comp/bol/components/Wallet/index.js +11 -15
- package/lib/composite-comp/bol/components/Wallet/mobile/index.js +314 -64
- package/lib/composite-comp/bol/components/Wallet/mobile/index.less +89 -13
- package/lib/composite-comp/bol/components/Wallet/pc/index.js +0 -2
- package/lib/composite-comp/bol/components/Wallet/pc/index.less +1 -40
- package/lib/composite-comp/bol/components/WalletNuri/defaultJSON.js +148 -0
- package/lib/composite-comp/bol/components/WalletNuri/index.js +84 -0
- package/lib/composite-comp/bol/components/WalletNuri/mobile/index.js +366 -0
- package/lib/composite-comp/bol/components/WalletNuri/mobile/index.less +22 -0
- package/lib/composite-comp/bol/config-panels/WalletConfig/WalletConfigImageGroup/index.js +1 -6
- package/lib/composite-comp/bol/config-panels/WalletConfig/WalletConfigSetting/index.js +201 -0
- package/lib/composite-comp/bol/config-panels/WalletConfig/WalletConfigSetting/index.less +9 -0
- package/lib/composite-comp/bol/config-panels/WalletConfig/index.js +11 -2
- package/lib/composite-comp/bol/config-panels/WalletNuriConfig/GroupList/defaultImg.png +0 -0
- package/lib/composite-comp/bol/config-panels/WalletNuriConfig/GroupList/index.js +100 -0
- package/lib/composite-comp/bol/config-panels/WalletNuriConfig/GroupList/index.less +72 -0
- package/lib/composite-comp/bol/config-panels/WalletNuriConfig/WalletNuriConfigImageGroup/index.js +123 -0
- package/lib/composite-comp/bol/config-panels/WalletNuriConfig/WalletNuriConfigImageGroup/index.less +0 -0
- package/lib/composite-comp/bol/config-panels/WalletNuriConfig/imgs/defaultImg.png +0 -0
- package/lib/composite-comp/bol/config-panels/WalletNuriConfig/index.js +61 -0
- package/lib/composite-comp/bol/second-config-panels/ImageTextSecondConfig/index.js +8 -6
- package/lib/composite-comp/bol/second-config-panels/WalletNuriSecondConfig/index.js +152 -0
- package/lib/composite-comp/bol/second-config-panels/WalletSecondConfig/index.js +58 -82
- package/lib/composite-comp/bol/second-config-panels/WalletSecondConfig/index.less +2 -0
- package/lib/composite-comp/common/components/AffiliateProductItem/imgs/icon-Balance2.svg +9 -0
- package/lib/composite-comp/common/components/AffiliateProductItem/imgs/icon-Koin.svg +40 -0
- package/lib/composite-comp/common/components/AffiliateProductItem/index.js +177 -0
- package/lib/composite-comp/common/components/AffiliateProductItem/index.less +129 -0
- package/lib/composite-comp/common/components/ImageLabel/index.less +9 -3
- package/lib/composite-comp/common/components/ProductItem/index.js +25 -17
- package/lib/composite-comp/common/components/ProductItem/index.less +17 -8
- package/lib/composite-comp/common/config-panels/CustomizeConfig/index.js +13 -0
- package/lib/composite-comp/common/config-panels/CustomizeConfig/index.less +3 -2
- package/lib/composite-comp/dito/components/AffiliateRecommend/defaultJSON.js +243 -0
- package/lib/composite-comp/dito/components/AffiliateRecommend/index.js +90 -0
- package/lib/composite-comp/dito/components/AffiliateRecommend/mobile/index.js +660 -0
- package/lib/composite-comp/dito/components/AffiliateRecommend/mobile/index.less +84 -0
- package/lib/composite-comp/dito/components/AffiliateRecommend/pc/index.js +728 -0
- package/lib/composite-comp/dito/components/AffiliateRecommend/pc/index.less +124 -0
- package/lib/composite-comp/dito/components/FlashDeal/mobile/index.js +8 -6
- package/lib/composite-comp/dito/components/FlashDeal/pc/index.js +8 -6
- package/lib/composite-comp/dito/components/HeadNavigation/defaultJSON.js +97 -0
- package/lib/composite-comp/dito/components/HeadNavigation/index.js +84 -0
- package/lib/composite-comp/dito/components/HeadNavigation/mobile/index.js +112 -0
- package/lib/composite-comp/dito/components/HeadNavigation/mobile/index.less +34 -0
- package/lib/composite-comp/dito/components/MenuNavigation/MenuNavMetaImage/index.js +206 -0
- package/lib/composite-comp/dito/components/MenuNavigation/MenuNavMetaImage/index.less +25 -0
- package/lib/composite-comp/dito/components/MenuNavigation/defaultJSON.js +107 -0
- package/lib/composite-comp/dito/components/MenuNavigation/index.js +84 -0
- package/lib/composite-comp/dito/components/MenuNavigation/mobile/index.js +87 -0
- package/lib/composite-comp/dito/components/MenuNavigation/mobile/index.less +8 -0
- package/lib/composite-comp/dito/components/Recommend/mobile/index.js +10 -9
- package/lib/composite-comp/dito/components/Recommend/pc/index.js +12 -11
- package/lib/composite-comp/dito/components/SearchBar/mobile/index.js +1 -1
- package/lib/composite-comp/dito/config-panels/AffiliateRecommendConfig/RecommendConfigContent/index.js +102 -0
- package/lib/composite-comp/dito/config-panels/AffiliateRecommendConfig/RecommendConfigContent/index.less +0 -0
- package/lib/composite-comp/dito/config-panels/AffiliateRecommendConfig/RecommendConfigGroup/index.js +148 -0
- package/lib/composite-comp/dito/config-panels/AffiliateRecommendConfig/RecommendConfigGroup/index.less +16 -0
- package/lib/composite-comp/dito/config-panels/AffiliateRecommendConfig/imgs/defaultImg.png +0 -0
- package/lib/composite-comp/dito/config-panels/AffiliateRecommendConfig/index.js +141 -0
- package/lib/composite-comp/dito/config-panels/HeadNavigationConfig/GroupList/index.js +203 -0
- package/lib/composite-comp/dito/config-panels/HeadNavigationConfig/GroupList/index.less +72 -0
- package/lib/composite-comp/dito/config-panels/HeadNavigationConfig/HeadNavConfigImageGroup/index.js +142 -0
- package/lib/composite-comp/dito/config-panels/HeadNavigationConfig/index.js +123 -0
- package/lib/composite-comp/dito/config-panels/HeadNavigationConfig/index.less +23 -0
- package/lib/composite-comp/dito/config-panels/MenuNavigationConfig/GroupList/index.js +203 -0
- package/lib/composite-comp/dito/config-panels/MenuNavigationConfig/GroupList/index.less +72 -0
- package/lib/composite-comp/dito/config-panels/MenuNavigationConfig/MenuNavConfigImageGroup/index.js +137 -0
- package/lib/composite-comp/dito/config-panels/MenuNavigationConfig/MenuNavConfigImageGroup/index.less +6 -0
- package/lib/composite-comp/dito/config-panels/MenuNavigationConfig/index.js +40 -0
- package/lib/composite-comp/dito/config-panels/RecommendConfig/RecommendConfigGroup/index.js +15 -11
- package/lib/composite-comp/dito/second-config-panels/AffiliateRecommendSecondConfig/AIRecommendation/index.js +431 -0
- package/lib/composite-comp/dito/second-config-panels/AffiliateRecommendSecondConfig/index.js +214 -0
- package/lib/composite-comp/dito/second-config-panels/AffiliateRecommendSecondConfig/index.less +15 -0
- package/lib/composite-comp/dito/second-config-panels/HeadNavigationSecondConfig/index.js +127 -0
- package/lib/composite-comp/dito/second-config-panels/MenuNavigationSecondConfig/index.js +127 -0
- package/lib/constants/component-types.js +27 -3
- package/lib/constants/index.js +26 -1
- package/lib/constants/layout.js +48 -1
- package/lib/core/Designer/ChatRobot/components/SearchCondition/index.js +110 -0
- package/lib/core/Designer/ChatRobot/components/SearchCondition/index.less +33 -0
- package/lib/core/Designer/ChatRobot/index.js +36 -14
- package/lib/core/Designer/ChatRobot/index.less +69 -28
- package/lib/core/Designer/ConfigPanel/index.js +8 -3
- package/lib/core/Designer/History/index.js +2 -2
- package/lib/core/Designer/PageCompList/index.js +8 -5
- package/lib/core/Designer/QuickMenuBar/index.js +5 -3
- package/lib/core/Designer/QuickMenuBar/index.less +4 -0
- package/lib/core/Designer/RenderHtml/index.js +18 -15
- package/lib/core/Designer/RenderHtml/index.less +1 -1
- package/lib/core/Designer/ToolBarModal/ToolBtn/components/AlignPicker/images/AlignCenterSVG.js +19 -6
- package/lib/core/Designer/ToolBarModal/ToolBtn/components/AlignPicker/images/AlignLeftSVG.js +19 -6
- package/lib/core/Designer/ToolBarModal/ToolBtn/components/AlignPicker/images/AlignRightSVG.js +19 -6
- package/lib/core/Designer/ToolBarModal/ToolBtn/components/BulletPicker/index.js +27 -6
- package/lib/core/Designer/ToolBarModal/ToolBtn/components/BulletPicker/index.less +4 -20
- package/lib/core/Designer/ToolBarModal/ToolBtn/components/ColorPickerBtn/UnderlineSelectPicker/index.js +77 -0
- package/lib/core/Designer/ToolBarModal/ToolBtn/components/ColorPickerBtn/UnderlineSelectPicker/index.less +27 -0
- package/lib/core/Designer/ToolBarModal/ToolBtn/components/ColorPickerBtn/index.js +36 -5
- package/lib/core/Designer/ToolBarModal/ToolBtn/components/ColorPickerBtn/index.less +17 -16
- package/lib/core/Designer/ToolBarModal/ToolBtn/components/OrderedPicker/index.js +27 -6
- package/lib/core/Designer/ToolBarModal/ToolBtn/components/OrderedPicker/index.less +4 -20
- package/lib/core/Designer/ToolBarModal/ToolBtn/images/AlignCenterSVG.js +40 -0
- package/lib/core/Designer/ToolBarModal/ToolBtn/images/AlignLeftSVG.js +40 -0
- package/lib/core/Designer/ToolBarModal/ToolBtn/images/AlignRightSVG.js +40 -0
- package/lib/core/Designer/ToolBarModal/ToolBtn/index.js +28 -3
- package/lib/core/Designer/ToolBarModal/ToolBtn/index.less +2 -1
- package/lib/core/Designer/ToolBarModal/index.js +68 -22
- package/lib/core/Designer/ToolBarModal/index.less +3 -2
- package/lib/core/Designer/index.js +12 -1
- package/lib/core/Renderer/index.js +55 -8
- package/lib/decorator/compositeDecorator.js +23 -0
- package/lib/locale/en/en.json +6 -1
- package/lib/locale/es/es.json +6 -1
- package/lib/locale/id/id.json +6 -1
- package/lib/meta-comp/components/Image/index.js +31 -25
- package/lib/meta-comp/components/Text/formats/textAlign.js +58 -0
- package/lib/meta-comp/components/Text/index.js +20 -1
- package/lib/meta-comp/components/Text/index.less +8 -0
- package/lib/meta-comp/config-panels/ButtonConfig/index.js +5 -5
- package/lib/meta-comp/config-panels/ImageConfig/index.js +48 -44
- package/lib/mobx/Frame.js +17 -2
- package/lib/utils/businessUtil.js +17 -6
- package/lib/utils/commonUtil.js +54 -4
- package/lib/utils/currencyUtil.js +9 -2
- package/package.json +1 -1
|
@@ -0,0 +1,417 @@
|
|
|
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
|
+
require("./index.less");
|
|
11
|
+
|
|
12
|
+
var _2 = require("..");
|
|
13
|
+
|
|
14
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
15
|
+
|
|
16
|
+
var __extends = void 0 && (void 0).__extends || function () {
|
|
17
|
+
var _extendStatics = function extendStatics(d, b) {
|
|
18
|
+
_extendStatics = Object.setPrototypeOf || {
|
|
19
|
+
__proto__: []
|
|
20
|
+
} instanceof Array && function (d, b) {
|
|
21
|
+
d.__proto__ = b;
|
|
22
|
+
} || function (d, b) {
|
|
23
|
+
for (var p in b) {
|
|
24
|
+
if (b.hasOwnProperty(p)) d[p] = b[p];
|
|
25
|
+
}
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
return _extendStatics(d, b);
|
|
29
|
+
};
|
|
30
|
+
|
|
31
|
+
return function (d, b) {
|
|
32
|
+
_extendStatics(d, b);
|
|
33
|
+
|
|
34
|
+
function __() {
|
|
35
|
+
this.constructor = d;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
39
|
+
};
|
|
40
|
+
}();
|
|
41
|
+
|
|
42
|
+
var __awaiter = void 0 && (void 0).__awaiter || function (thisArg, _arguments, P, generator) {
|
|
43
|
+
function adopt(value) {
|
|
44
|
+
return value instanceof P ? value : new P(function (resolve) {
|
|
45
|
+
resolve(value);
|
|
46
|
+
});
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
50
|
+
function fulfilled(value) {
|
|
51
|
+
try {
|
|
52
|
+
step(generator.next(value));
|
|
53
|
+
} catch (e) {
|
|
54
|
+
reject(e);
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
function rejected(value) {
|
|
59
|
+
try {
|
|
60
|
+
step(generator["throw"](value));
|
|
61
|
+
} catch (e) {
|
|
62
|
+
reject(e);
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
function step(result) {
|
|
67
|
+
result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
71
|
+
});
|
|
72
|
+
};
|
|
73
|
+
|
|
74
|
+
var __generator = void 0 && (void 0).__generator || function (thisArg, body) {
|
|
75
|
+
var _ = {
|
|
76
|
+
label: 0,
|
|
77
|
+
sent: function sent() {
|
|
78
|
+
if (t[0] & 1) throw t[1];
|
|
79
|
+
return t[1];
|
|
80
|
+
},
|
|
81
|
+
trys: [],
|
|
82
|
+
ops: []
|
|
83
|
+
},
|
|
84
|
+
f,
|
|
85
|
+
y,
|
|
86
|
+
t,
|
|
87
|
+
g;
|
|
88
|
+
return g = {
|
|
89
|
+
next: verb(0),
|
|
90
|
+
"throw": verb(1),
|
|
91
|
+
"return": verb(2)
|
|
92
|
+
}, typeof Symbol === "function" && (g[Symbol.iterator] = function () {
|
|
93
|
+
return this;
|
|
94
|
+
}), g;
|
|
95
|
+
|
|
96
|
+
function verb(n) {
|
|
97
|
+
return function (v) {
|
|
98
|
+
return step([n, v]);
|
|
99
|
+
};
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
function step(op) {
|
|
103
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
104
|
+
|
|
105
|
+
while (_) {
|
|
106
|
+
try {
|
|
107
|
+
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;
|
|
108
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
109
|
+
|
|
110
|
+
switch (op[0]) {
|
|
111
|
+
case 0:
|
|
112
|
+
case 1:
|
|
113
|
+
t = op;
|
|
114
|
+
break;
|
|
115
|
+
|
|
116
|
+
case 4:
|
|
117
|
+
_.label++;
|
|
118
|
+
return {
|
|
119
|
+
value: op[1],
|
|
120
|
+
done: false
|
|
121
|
+
};
|
|
122
|
+
|
|
123
|
+
case 5:
|
|
124
|
+
_.label++;
|
|
125
|
+
y = op[1];
|
|
126
|
+
op = [0];
|
|
127
|
+
continue;
|
|
128
|
+
|
|
129
|
+
case 7:
|
|
130
|
+
op = _.ops.pop();
|
|
131
|
+
|
|
132
|
+
_.trys.pop();
|
|
133
|
+
|
|
134
|
+
continue;
|
|
135
|
+
|
|
136
|
+
default:
|
|
137
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) {
|
|
138
|
+
_ = 0;
|
|
139
|
+
continue;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
if (op[0] === 3 && (!t || op[1] > t[0] && op[1] < t[3])) {
|
|
143
|
+
_.label = op[1];
|
|
144
|
+
break;
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
if (op[0] === 6 && _.label < t[1]) {
|
|
148
|
+
_.label = t[1];
|
|
149
|
+
t = op;
|
|
150
|
+
break;
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
if (t && _.label < t[2]) {
|
|
154
|
+
_.label = t[2];
|
|
155
|
+
|
|
156
|
+
_.ops.push(op);
|
|
157
|
+
|
|
158
|
+
break;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
if (t[2]) _.ops.pop();
|
|
162
|
+
|
|
163
|
+
_.trys.pop();
|
|
164
|
+
|
|
165
|
+
continue;
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
op = body.call(thisArg, _);
|
|
169
|
+
} catch (e) {
|
|
170
|
+
op = [6, e];
|
|
171
|
+
y = 0;
|
|
172
|
+
} finally {
|
|
173
|
+
f = t = 0;
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
if (op[0] & 5) throw op[1];
|
|
178
|
+
return {
|
|
179
|
+
value: op[0] ? op[1] : void 0,
|
|
180
|
+
done: true
|
|
181
|
+
};
|
|
182
|
+
}
|
|
183
|
+
};
|
|
184
|
+
|
|
185
|
+
// import { Iconfont } from 'src/components/common';
|
|
186
|
+
function urlToDataUrl(url) {
|
|
187
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
188
|
+
var response, blob_1, error_1;
|
|
189
|
+
return __generator(this, function (_a) {
|
|
190
|
+
switch (_a.label) {
|
|
191
|
+
case 0:
|
|
192
|
+
_a.trys.push([0, 3,, 4]);
|
|
193
|
+
|
|
194
|
+
return [4
|
|
195
|
+
/*yield*/
|
|
196
|
+
, fetch(url)];
|
|
197
|
+
|
|
198
|
+
case 1:
|
|
199
|
+
response = _a.sent();
|
|
200
|
+
return [4
|
|
201
|
+
/*yield*/
|
|
202
|
+
, response.blob()];
|
|
203
|
+
|
|
204
|
+
case 2:
|
|
205
|
+
blob_1 = _a.sent();
|
|
206
|
+
return [2
|
|
207
|
+
/*return*/
|
|
208
|
+
, new Promise(function (resolve, reject) {
|
|
209
|
+
var reader = new FileReader();
|
|
210
|
+
|
|
211
|
+
reader.onload = function () {
|
|
212
|
+
return resolve(reader.result);
|
|
213
|
+
};
|
|
214
|
+
|
|
215
|
+
reader.onerror = reject;
|
|
216
|
+
reader.readAsDataURL(blob_1);
|
|
217
|
+
})];
|
|
218
|
+
|
|
219
|
+
case 3:
|
|
220
|
+
error_1 = _a.sent();
|
|
221
|
+
console.error('Error converting URL to Data URL:', error_1);
|
|
222
|
+
return [2
|
|
223
|
+
/*return*/
|
|
224
|
+
, null];
|
|
225
|
+
|
|
226
|
+
case 4:
|
|
227
|
+
return [2
|
|
228
|
+
/*return*/
|
|
229
|
+
];
|
|
230
|
+
}
|
|
231
|
+
});
|
|
232
|
+
});
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
var MyModal =
|
|
236
|
+
/** @class */
|
|
237
|
+
function (_super) {
|
|
238
|
+
__extends(MyModal, _super);
|
|
239
|
+
|
|
240
|
+
function MyModal(props) {
|
|
241
|
+
var _this = _super.call(this, props) || this;
|
|
242
|
+
|
|
243
|
+
_this.confirm = function () {
|
|
244
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
245
|
+
var _a, onConfirm, onClose_1, error_2;
|
|
246
|
+
|
|
247
|
+
var _b;
|
|
248
|
+
|
|
249
|
+
return __generator(this, function (_c) {
|
|
250
|
+
switch (_c.label) {
|
|
251
|
+
case 0:
|
|
252
|
+
_c.trys.push([0, 3,, 4]);
|
|
253
|
+
|
|
254
|
+
_a = this.props, onConfirm = _a.onConfirm, onClose_1 = _a.onClose;
|
|
255
|
+
if (!onConfirm) return [3
|
|
256
|
+
/*break*/
|
|
257
|
+
, 2];
|
|
258
|
+
return [4
|
|
259
|
+
/*yield*/
|
|
260
|
+
, onConfirm()];
|
|
261
|
+
|
|
262
|
+
case 1:
|
|
263
|
+
_c.sent();
|
|
264
|
+
|
|
265
|
+
_c.label = 2;
|
|
266
|
+
|
|
267
|
+
case 2:
|
|
268
|
+
(_b = this.parentRef.current.querySelector('.tip-content')) === null || _b === void 0 ? void 0 : _b.classList.remove('scroll-animation');
|
|
269
|
+
setTimeout(function () {
|
|
270
|
+
onClose_1();
|
|
271
|
+
}, 300);
|
|
272
|
+
return [3
|
|
273
|
+
/*break*/
|
|
274
|
+
, 4];
|
|
275
|
+
|
|
276
|
+
case 3:
|
|
277
|
+
error_2 = _c.sent();
|
|
278
|
+
debug(error_2);
|
|
279
|
+
return [3
|
|
280
|
+
/*break*/
|
|
281
|
+
, 4];
|
|
282
|
+
|
|
283
|
+
case 4:
|
|
284
|
+
return [2
|
|
285
|
+
/*return*/
|
|
286
|
+
];
|
|
287
|
+
}
|
|
288
|
+
});
|
|
289
|
+
});
|
|
290
|
+
};
|
|
291
|
+
|
|
292
|
+
_this.cancel = function () {
|
|
293
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
294
|
+
var _a, onCancel, onClose_2, error_3;
|
|
295
|
+
|
|
296
|
+
var _b;
|
|
297
|
+
|
|
298
|
+
return __generator(this, function (_c) {
|
|
299
|
+
switch (_c.label) {
|
|
300
|
+
case 0:
|
|
301
|
+
_c.trys.push([0, 2,, 3]);
|
|
302
|
+
|
|
303
|
+
_a = this.props, onCancel = _a.onCancel, onClose_2 = _a.onClose;
|
|
304
|
+
return [4
|
|
305
|
+
/*yield*/
|
|
306
|
+
, onCancel()];
|
|
307
|
+
|
|
308
|
+
case 1:
|
|
309
|
+
_c.sent();
|
|
310
|
+
|
|
311
|
+
(_b = this.parentRef.current.querySelector('.tip-content')) === null || _b === void 0 ? void 0 : _b.classList.remove('scroll-animation');
|
|
312
|
+
setTimeout(function () {
|
|
313
|
+
onClose_2();
|
|
314
|
+
}, 300);
|
|
315
|
+
return [3
|
|
316
|
+
/*break*/
|
|
317
|
+
, 3];
|
|
318
|
+
|
|
319
|
+
case 2:
|
|
320
|
+
error_3 = _c.sent();
|
|
321
|
+
debug(error_3);
|
|
322
|
+
return [3
|
|
323
|
+
/*break*/
|
|
324
|
+
, 3];
|
|
325
|
+
|
|
326
|
+
case 3:
|
|
327
|
+
return [2
|
|
328
|
+
/*return*/
|
|
329
|
+
];
|
|
330
|
+
}
|
|
331
|
+
});
|
|
332
|
+
});
|
|
333
|
+
};
|
|
334
|
+
|
|
335
|
+
_this.parentRef = /*#__PURE__*/_react["default"].createRef();
|
|
336
|
+
return _this;
|
|
337
|
+
}
|
|
338
|
+
|
|
339
|
+
MyModal.prototype.componentDidMount = function () {
|
|
340
|
+
var _this = this;
|
|
341
|
+
|
|
342
|
+
var messageImg = this.props.messageImg;
|
|
343
|
+
|
|
344
|
+
if (messageImg) {
|
|
345
|
+
urlToDataUrl(messageImg).then(function () {
|
|
346
|
+
var _a;
|
|
347
|
+
|
|
348
|
+
(_a = _this.parentRef.current.querySelector('.tip-content')) === null || _a === void 0 ? void 0 : _a.classList.add('scroll-animation');
|
|
349
|
+
});
|
|
350
|
+
}
|
|
351
|
+
};
|
|
352
|
+
|
|
353
|
+
MyModal.prototype.render = function () {
|
|
354
|
+
// const { content } = this.props;
|
|
355
|
+
var _a = this.props,
|
|
356
|
+
title = _a.title,
|
|
357
|
+
titleStyle = _a.titleStyle,
|
|
358
|
+
message = _a.message,
|
|
359
|
+
confirmText = _a.confirmText,
|
|
360
|
+
messageImg = _a.messageImg,
|
|
361
|
+
cancelText = _a.cancelText,
|
|
362
|
+
onClose = _a.onClose,
|
|
363
|
+
hideCancel = _a.hideCancel,
|
|
364
|
+
isPreview = _a.isPreview;
|
|
365
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
366
|
+
ref: this.parentRef,
|
|
367
|
+
className: "tip-modal-wrap",
|
|
368
|
+
style: {
|
|
369
|
+
position: isPreview ? 'absolute' : 'fixed'
|
|
370
|
+
}
|
|
371
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
372
|
+
className: "tip-background",
|
|
373
|
+
onClick: onClose
|
|
374
|
+
}), /*#__PURE__*/_react["default"].createElement("div", {
|
|
375
|
+
className: "tip-content"
|
|
376
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
377
|
+
className: "content-head"
|
|
378
|
+
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
379
|
+
style: titleStyle
|
|
380
|
+
}, title), /*#__PURE__*/_react["default"].createElement("div", {
|
|
381
|
+
className: "close-icon",
|
|
382
|
+
onClick: onClose
|
|
383
|
+
}, /*#__PURE__*/_react["default"].createElement(_2.Iconfont, {
|
|
384
|
+
color: "#8493AF",
|
|
385
|
+
size: 16,
|
|
386
|
+
type: "icon-close"
|
|
387
|
+
}))), /*#__PURE__*/_react["default"].createElement("div", {
|
|
388
|
+
className: "content-body"
|
|
389
|
+
}, message && /*#__PURE__*/_react["default"].createElement("div", null, message), messageImg && /*#__PURE__*/_react["default"].createElement("img", {
|
|
390
|
+
alt: "tip",
|
|
391
|
+
src: messageImg
|
|
392
|
+
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
393
|
+
className: "close-wrap"
|
|
394
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
395
|
+
className: "close-btn",
|
|
396
|
+
onClick: this.confirm
|
|
397
|
+
}, confirmText), !hideCancel && /*#__PURE__*/_react["default"].createElement("div", {
|
|
398
|
+
className: "close-btn",
|
|
399
|
+
onClick: this.cancel
|
|
400
|
+
}, cancelText))));
|
|
401
|
+
};
|
|
402
|
+
|
|
403
|
+
MyModal.defaultProps = {
|
|
404
|
+
hideCancel: true,
|
|
405
|
+
title: '',
|
|
406
|
+
message: '',
|
|
407
|
+
messageImg: '',
|
|
408
|
+
confirmText: 'OK',
|
|
409
|
+
cancelText: 'NO',
|
|
410
|
+
onConfirm: function onConfirm() {},
|
|
411
|
+
onCancel: function onCancel() {}
|
|
412
|
+
};
|
|
413
|
+
return MyModal;
|
|
414
|
+
}(_react["default"].Component);
|
|
415
|
+
|
|
416
|
+
var _default = MyModal;
|
|
417
|
+
exports["default"] = _default;
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
.tip-modal-wrap {
|
|
2
|
+
width: 100%;
|
|
3
|
+
height: 100%;
|
|
4
|
+
position: fixed;
|
|
5
|
+
top: 0;
|
|
6
|
+
left: 0;
|
|
7
|
+
z-index: 9999;
|
|
8
|
+
.tip-background {
|
|
9
|
+
width: 100%;
|
|
10
|
+
height: 100%;
|
|
11
|
+
background-color: rgba(0, 0, 0, 0.7);
|
|
12
|
+
}
|
|
13
|
+
.tip-content {
|
|
14
|
+
border-radius: 16px 16px 0px 0px;
|
|
15
|
+
background-color: #fff;
|
|
16
|
+
padding: 0 12px;
|
|
17
|
+
position: absolute;
|
|
18
|
+
bottom: 0;
|
|
19
|
+
left: 0;
|
|
20
|
+
width: 100%;
|
|
21
|
+
transition: all 0.3s;
|
|
22
|
+
transform: translateY(100%);
|
|
23
|
+
|
|
24
|
+
.content-head {
|
|
25
|
+
text-align: center;
|
|
26
|
+
color: #323233;
|
|
27
|
+
font-family: Open Sans;
|
|
28
|
+
font-size: 16px;
|
|
29
|
+
font-weight: 400;
|
|
30
|
+
line-height: 24px;
|
|
31
|
+
letter-spacing: 0px;
|
|
32
|
+
position: relative;
|
|
33
|
+
padding: 10px 0;
|
|
34
|
+
// margin-bottom: 20px;
|
|
35
|
+
.close-icon {
|
|
36
|
+
position: absolute;
|
|
37
|
+
right: 16px;
|
|
38
|
+
top: 10px;
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
.content-body {
|
|
42
|
+
width: 100%;
|
|
43
|
+
margin-bottom: 5px;
|
|
44
|
+
max-height: 500px;
|
|
45
|
+
overflow-y: auto;
|
|
46
|
+
&> img {
|
|
47
|
+
width: 100%;
|
|
48
|
+
// max-width: 300px;
|
|
49
|
+
height: fit-content;
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
.close-wrap {
|
|
53
|
+
margin: 6px 2px;
|
|
54
|
+
.close-btn {
|
|
55
|
+
border-radius: 4px;
|
|
56
|
+
background-color: #E65427;
|
|
57
|
+
font-size: 14px;
|
|
58
|
+
font-weight: 400;
|
|
59
|
+
line-height: 20px;
|
|
60
|
+
text-align: center;
|
|
61
|
+
padding: 8px 0;
|
|
62
|
+
color: #fff;
|
|
63
|
+
flex: 1;
|
|
64
|
+
&:nth-of-type(2) {
|
|
65
|
+
margin-left: 10px;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
.scroll-animation {
|
|
71
|
+
transform: translateY(0);
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
|
|
@@ -216,8 +216,7 @@ var promType = {
|
|
|
216
216
|
FLASH_SALE: '2',
|
|
217
217
|
GROUP_BUY: '4'
|
|
218
218
|
};
|
|
219
|
-
var Option = _antd.Select.Option
|
|
220
|
-
OptGroup = _antd.Select.OptGroup;
|
|
219
|
+
var Option = _antd.Select.Option;
|
|
221
220
|
var InputGroup = _antd.Input.Group;
|
|
222
221
|
|
|
223
222
|
var ProductModal = function ProductModal(props) {
|
|
@@ -609,7 +608,7 @@ var ProductModal = function ProductModal(props) {
|
|
|
609
608
|
value: v.storeId
|
|
610
609
|
}, v.storeName);
|
|
611
610
|
}))), /*#__PURE__*/_react["default"].createElement(_antd.Form.Item, {
|
|
612
|
-
label: "
|
|
611
|
+
label: "Label"
|
|
613
612
|
}, /*#__PURE__*/_react["default"].createElement(_antd.Select, {
|
|
614
613
|
defaultValue: selLabelData.children || null,
|
|
615
614
|
onChange: function onChange(v, o) {
|
|
@@ -19,6 +19,8 @@ var _ProductModal = _interopRequireDefault(require("../ProductModal"));
|
|
|
19
19
|
|
|
20
20
|
require("./index.less");
|
|
21
21
|
|
|
22
|
+
var _AffiliateProductModal = _interopRequireDefault(require("../AffiliateProductModal"));
|
|
23
|
+
|
|
22
24
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
23
25
|
|
|
24
26
|
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); }
|
|
@@ -172,7 +174,8 @@ function ProductSource(_a) {
|
|
|
172
174
|
var _this = this;
|
|
173
175
|
|
|
174
176
|
var value = _a.value,
|
|
175
|
-
onChange = _a.onChange
|
|
177
|
+
onChange = _a.onChange,
|
|
178
|
+
isAffiliate = _a.isAffiliate;
|
|
176
179
|
|
|
177
180
|
var _b = (0, _react.useState)([]),
|
|
178
181
|
selectedProds = _b[0],
|
|
@@ -184,18 +187,30 @@ function ProductSource(_a) {
|
|
|
184
187
|
|
|
185
188
|
var onSelectProduct = function onSelectProduct() {
|
|
186
189
|
return __awaiter(_this, void 0, void 0, function () {
|
|
187
|
-
var list;
|
|
190
|
+
var url, param, list;
|
|
188
191
|
return __generator(this, function (_a) {
|
|
189
192
|
switch (_a.label) {
|
|
190
193
|
case 0:
|
|
191
194
|
if (!(value && value.length > 0)) return [3
|
|
192
195
|
/*break*/
|
|
193
196
|
, 2];
|
|
197
|
+
url = "/designer/v1/" + window.magicDesign.MBaseUrl + "/products";
|
|
198
|
+
param = {
|
|
199
|
+
products: value
|
|
200
|
+
};
|
|
201
|
+
|
|
202
|
+
if (isAffiliate) {
|
|
203
|
+
url = "/designer/v1/" + window.magicDesign.MBaseUrl + "/distributor/product/list";
|
|
204
|
+
param = {
|
|
205
|
+
affiliateProductIds: value,
|
|
206
|
+
pageSize: value.length,
|
|
207
|
+
pageIndex: 1
|
|
208
|
+
};
|
|
209
|
+
}
|
|
210
|
+
|
|
194
211
|
return [4
|
|
195
212
|
/*yield*/
|
|
196
|
-
, (0, _commonUtil.commonFetch)(
|
|
197
|
-
products: value
|
|
198
|
-
}, 'GET')];
|
|
213
|
+
, (0, _commonUtil.commonFetch)(url, param, 'GET')];
|
|
199
214
|
|
|
200
215
|
case 1:
|
|
201
216
|
list = _a.sent().list;
|
|
@@ -219,9 +234,18 @@ function ProductSource(_a) {
|
|
|
219
234
|
};
|
|
220
235
|
|
|
221
236
|
var handleModalSave = function handleModalSave(list) {
|
|
222
|
-
var ids =
|
|
223
|
-
|
|
224
|
-
|
|
237
|
+
var ids = '';
|
|
238
|
+
|
|
239
|
+
if (isAffiliate) {
|
|
240
|
+
ids = list.map(function (prod) {
|
|
241
|
+
return prod.affiliateProductId;
|
|
242
|
+
}).join(',');
|
|
243
|
+
} else {
|
|
244
|
+
ids = list.map(function (prod) {
|
|
245
|
+
return prod.productId;
|
|
246
|
+
}).join(',');
|
|
247
|
+
}
|
|
248
|
+
|
|
225
249
|
onChange(ids);
|
|
226
250
|
};
|
|
227
251
|
|
|
@@ -242,7 +266,15 @@ function ProductSource(_a) {
|
|
|
242
266
|
className: "total"
|
|
243
267
|
}, (0, _locale.i18n)('TOTAL_PRODUCTS', {
|
|
244
268
|
count: getLength()
|
|
245
|
-
})), visible && /*#__PURE__*/_react["default"].createElement(
|
|
269
|
+
})), visible && (isAffiliate ? /*#__PURE__*/_react["default"].createElement(_AffiliateProductModal["default"], {
|
|
270
|
+
closeModal: function closeModal() {
|
|
271
|
+
return setVisbile(false);
|
|
272
|
+
},
|
|
273
|
+
defaultList: selectedProds,
|
|
274
|
+
handleModalSave: handleModalSave,
|
|
275
|
+
maxSelect: 100,
|
|
276
|
+
visible: visible
|
|
277
|
+
}) : /*#__PURE__*/_react["default"].createElement(_ProductModal["default"], {
|
|
246
278
|
closeModal: function closeModal() {
|
|
247
279
|
return setVisbile(false);
|
|
248
280
|
},
|
|
@@ -250,5 +282,5 @@ function ProductSource(_a) {
|
|
|
250
282
|
handleModalSave: handleModalSave,
|
|
251
283
|
maxSelect: 100,
|
|
252
284
|
visible: visible
|
|
253
|
-
}));
|
|
285
|
+
})));
|
|
254
286
|
}
|
|
@@ -66,7 +66,8 @@ function (_super) {
|
|
|
66
66
|
var _a = this.props,
|
|
67
67
|
value = _a.value,
|
|
68
68
|
_onChange = _a.onChange,
|
|
69
|
-
disabled = _a.disabled
|
|
69
|
+
disabled = _a.disabled,
|
|
70
|
+
onlySpecificCode = _a.onlySpecificCode; // 弹框选择url不可编辑,需要先清除
|
|
70
71
|
|
|
71
72
|
var editable = !value || !value.type;
|
|
72
73
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
@@ -119,6 +120,7 @@ function (_super) {
|
|
|
119
120
|
visible: false
|
|
120
121
|
});
|
|
121
122
|
},
|
|
123
|
+
onlySpecificCode: onlySpecificCode,
|
|
122
124
|
visible: visible
|
|
123
125
|
}));
|
|
124
126
|
};
|
package/lib/common/index.js
CHANGED
|
@@ -21,6 +21,12 @@ Object.defineProperty(exports, "ButtonIconLayout", {
|
|
|
21
21
|
return _ButtonIconLayout["default"];
|
|
22
22
|
}
|
|
23
23
|
});
|
|
24
|
+
Object.defineProperty(exports, "CardCarousel", {
|
|
25
|
+
enumerable: true,
|
|
26
|
+
get: function get() {
|
|
27
|
+
return _CardCarousel["default"];
|
|
28
|
+
}
|
|
29
|
+
});
|
|
24
30
|
Object.defineProperty(exports, "Collapse", {
|
|
25
31
|
enumerable: true,
|
|
26
32
|
get: function get() {
|
|
@@ -81,6 +87,12 @@ Object.defineProperty(exports, "LayoutSelector", {
|
|
|
81
87
|
return _LayoutSelector["default"];
|
|
82
88
|
}
|
|
83
89
|
});
|
|
90
|
+
Object.defineProperty(exports, "MyModal", {
|
|
91
|
+
enumerable: true,
|
|
92
|
+
get: function get() {
|
|
93
|
+
return _MyModal["default"];
|
|
94
|
+
}
|
|
95
|
+
});
|
|
84
96
|
Object.defineProperty(exports, "ProductSource", {
|
|
85
97
|
enumerable: true,
|
|
86
98
|
get: function get() {
|
|
@@ -172,4 +184,8 @@ var _InputNumber = _interopRequireDefault(require("./InputNumber"));
|
|
|
172
184
|
|
|
173
185
|
var _VideoUpload = _interopRequireDefault(require("./VideoUpload"));
|
|
174
186
|
|
|
187
|
+
var _CardCarousel = _interopRequireDefault(require("./CardCarousel"));
|
|
188
|
+
|
|
189
|
+
var _MyModal = _interopRequireDefault(require("./MyModal"));
|
|
190
|
+
|
|
175
191
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
@@ -211,7 +211,10 @@ function (_super) {
|
|
|
211
211
|
onClick: function onClick() {
|
|
212
212
|
/** PTO 定制GA */
|
|
213
213
|
if (window.magicDesign.pushGA) {
|
|
214
|
-
window.magicDesign.pushGA({}, 'select_promotion'
|
|
214
|
+
window.magicDesign.pushGA({}, 'select_promotion', {
|
|
215
|
+
event_label: (0, _ConfigPanel.getSecondConfigName)(data, item.id),
|
|
216
|
+
promotion_name: (0, _ConfigPanel.getSecondConfigName)(data, item.id)
|
|
217
|
+
});
|
|
215
218
|
}
|
|
216
219
|
},
|
|
217
220
|
onMouseEnter: _this.mouseEnterWrap,
|
|
@@ -11,7 +11,7 @@ require("./index.less");
|
|
|
11
11
|
|
|
12
12
|
var _classnames = _interopRequireDefault(require("classnames"));
|
|
13
13
|
|
|
14
|
-
var
|
|
14
|
+
var _debounce = _interopRequireDefault(require("lodash/debounce"));
|
|
15
15
|
|
|
16
16
|
var _AlignSelector = require("../../../../../common/AlignSelector");
|
|
17
17
|
|
|
@@ -227,7 +227,7 @@ function (_super) {
|
|
|
227
227
|
this.layout = data.customize.layout.pcLayout;
|
|
228
228
|
this.pcRowNum = data.customize.pcRowNum;
|
|
229
229
|
this.listenCardWidth();
|
|
230
|
-
window.addEventListener('resize', (0,
|
|
230
|
+
window.addEventListener('resize', (0, _debounce["default"])(this.listenCardWidth));
|
|
231
231
|
};
|
|
232
232
|
|
|
233
233
|
ImageTextPc.prototype.componentWillUnmount = function () {
|
|
@@ -91,8 +91,7 @@ function (_super) {
|
|
|
91
91
|
|
|
92
92
|
|
|
93
93
|
Video.prototype.render = function () {
|
|
94
|
-
var nodeData = this.props.nodeData;
|
|
95
|
-
|
|
94
|
+
var nodeData = this.props.nodeData;
|
|
96
95
|
return /*#__PURE__*/_react["default"].createElement("div", null, window.magicDesign.device === 'pc' ? /*#__PURE__*/_react["default"].createElement(_pc["default"], {
|
|
97
96
|
data: nodeData
|
|
98
97
|
}) : /*#__PURE__*/_react["default"].createElement(_mobile["default"], {
|