@fonixtree/magic-design 1.0.67 → 1.0.69

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.
Files changed (419) hide show
  1. package/es/assets/fonts/.DS_Store +0 -0
  2. package/es/assets/fonts/Trueno-Light.otf +0 -0
  3. package/es/assets/fonts/Trueno-Regular.otf +0 -0
  4. package/es/assets/fonts/TruenoBd.otf +0 -0
  5. package/es/assets/fonts/magic-box-iconfont.css +62 -6
  6. package/es/assets/fonts/magic-box-iconfont.css.bak +35 -3
  7. package/es/assets/fonts/magic-box-iconfont.js +1 -1
  8. package/es/assets/fonts/magic-box-iconfont.js.bak +1 -1
  9. package/es/assets/fonts/magic-box-iconfont.ttf +0 -0
  10. package/es/assets/fonts/magic-box-iconfont.woff +0 -0
  11. package/es/assets/fonts/magic-box-iconfont.woff2 +0 -0
  12. package/es/assets/images/base64/index.js +36 -2
  13. package/es/assets/images/layout-icon/walletLayout2.png +0 -0
  14. package/es/assets/images/layout-icon/walletNuriLayout1.png +0 -0
  15. package/es/assets/less/button.less +5 -0
  16. package/es/assets/less/cylon-antd.less +7246 -1686
  17. package/es/assets/less/font.less +22 -0
  18. package/es/common/AffiliateProductModal/index.js +582 -0
  19. package/es/common/AffiliateProductModal/index.less +146 -0
  20. package/es/common/Button/index.less +0 -1
  21. package/es/common/CardCarousel/index.js +171 -0
  22. package/es/common/CardCarousel/index.less +28 -0
  23. package/es/common/CountDown/index.js +20 -11
  24. package/es/common/CropperModal/index.js +126 -0
  25. package/es/common/CropperModal/index.less +29 -0
  26. package/es/common/GroupList/index.js +7 -2
  27. package/es/common/ImagePicker/index.js +1 -3
  28. package/es/common/LinkModal/CouponTable/index.js +3 -3
  29. package/es/common/LinkModal/CustomTable/index.js +1 -0
  30. package/es/common/LinkModal/FunctionTable/index.js +2 -1
  31. package/es/common/LinkModal/index.js +14 -2
  32. package/es/common/MagicLink/index.js +2 -2
  33. package/es/common/MyModal/index.js +417 -0
  34. package/es/common/MyModal/index.less +74 -0
  35. package/es/common/ProductModal/index.js +38 -3
  36. package/es/common/ProductSource/index.js +59 -18
  37. package/es/common/UrlPicker/AnchorModal/index.js +170 -0
  38. package/es/common/UrlPicker/AnchorModal/index.less +21 -0
  39. package/es/common/UrlPicker/index.js +52 -9
  40. package/es/common/index.js +24 -0
  41. package/es/composite-comp/bol/components/Banner/mobile/index.js +1 -2
  42. package/es/composite-comp/bol/components/Banner/mobile/index.less +52 -78
  43. package/es/composite-comp/bol/components/Carousel/mobile/index.less +81 -100
  44. package/es/composite-comp/bol/components/ImageGallery/mobile/index.less +15 -22
  45. package/es/composite-comp/bol/components/ImageText/mobile/index.less +233 -292
  46. package/es/composite-comp/bol/components/Video/index.js +1 -2
  47. package/es/composite-comp/bol/components/Video/mobile/Layout1/index.less +21 -27
  48. package/es/composite-comp/bol/components/Video/mobile/Layout2/index.less +36 -45
  49. package/es/composite-comp/bol/components/Video/mobile/Layout3/index.less +43 -54
  50. package/es/composite-comp/bol/components/Video/mobile/index.less +2 -3
  51. package/es/composite-comp/bol/components/Wallet/defaultJSON.js +112 -88
  52. package/es/composite-comp/bol/components/Wallet/index.js +11 -15
  53. package/es/composite-comp/bol/components/Wallet/mobile/index.js +314 -64
  54. package/es/composite-comp/bol/components/Wallet/mobile/index.less +103 -40
  55. package/es/composite-comp/bol/components/Wallet/pc/index.js +0 -2
  56. package/es/composite-comp/bol/components/Wallet/pc/index.less +1 -40
  57. package/es/composite-comp/bol/components/WalletNuri/defaultJSON.js +148 -0
  58. package/es/composite-comp/bol/components/WalletNuri/index.js +84 -0
  59. package/es/composite-comp/bol/components/WalletNuri/mobile/index.js +366 -0
  60. package/es/composite-comp/bol/components/WalletNuri/mobile/index.less +22 -0
  61. package/es/composite-comp/bol/config-panels/WalletConfig/WalletConfigImageGroup/index.js +1 -6
  62. package/es/composite-comp/bol/config-panels/WalletConfig/WalletConfigSetting/index.js +201 -0
  63. package/es/composite-comp/bol/config-panels/WalletConfig/WalletConfigSetting/index.less +9 -0
  64. package/es/composite-comp/bol/config-panels/WalletConfig/index.js +11 -2
  65. package/es/composite-comp/bol/config-panels/WalletNuriConfig/GroupList/defaultImg.png +0 -0
  66. package/es/composite-comp/bol/config-panels/WalletNuriConfig/GroupList/index.js +100 -0
  67. package/es/composite-comp/bol/config-panels/WalletNuriConfig/GroupList/index.less +72 -0
  68. package/es/composite-comp/bol/config-panels/WalletNuriConfig/WalletNuriConfigImageGroup/index.js +123 -0
  69. package/es/composite-comp/bol/config-panels/WalletNuriConfig/WalletNuriConfigImageGroup/index.less +0 -0
  70. package/es/composite-comp/bol/config-panels/WalletNuriConfig/imgs/defaultImg.png +0 -0
  71. package/es/composite-comp/bol/config-panels/WalletNuriConfig/index.js +61 -0
  72. package/es/composite-comp/bol/second-config-panels/ImageTextSecondConfig/index.js +2 -2
  73. package/es/composite-comp/bol/second-config-panels/WalletNuriSecondConfig/index.js +152 -0
  74. package/es/composite-comp/bol/second-config-panels/WalletSecondConfig/index.js +58 -82
  75. package/es/composite-comp/bol/second-config-panels/WalletSecondConfig/index.less +2 -0
  76. package/es/composite-comp/common/components/AffiliateProductItem/imgs/icon-Balance2.svg +9 -0
  77. package/es/composite-comp/common/components/AffiliateProductItem/imgs/icon-Koin.svg +40 -0
  78. package/es/composite-comp/common/components/AffiliateProductItem/index.js +168 -0
  79. package/es/composite-comp/common/components/AffiliateProductItem/index.less +129 -0
  80. package/es/composite-comp/common/components/ProductItem/index.js +22 -20
  81. package/es/composite-comp/common/components/ProductItem/index.less +2 -12
  82. package/es/composite-comp/common/config-panels/CustomizeConfig/index.js +13 -0
  83. package/es/composite-comp/common/config-panels/CustomizeConfig/index.less +3 -2
  84. package/es/composite-comp/common/config-panels/SpacingConfig/index.js +1 -0
  85. package/es/composite-comp/dito/components/AffiliateRecommend/defaultJSON.js +243 -0
  86. package/es/composite-comp/dito/components/AffiliateRecommend/index.js +90 -0
  87. package/es/composite-comp/dito/components/AffiliateRecommend/mobile/index.js +660 -0
  88. package/es/composite-comp/dito/components/AffiliateRecommend/mobile/index.less +84 -0
  89. package/es/composite-comp/dito/components/AffiliateRecommend/pc/index.js +728 -0
  90. package/es/composite-comp/dito/components/AffiliateRecommend/pc/index.less +124 -0
  91. package/es/composite-comp/dito/components/CommonFunctions/defaultJSON.js +92 -0
  92. package/es/composite-comp/dito/components/CommonFunctions/index.js +84 -0
  93. package/es/composite-comp/dito/components/CommonFunctions/mobile/index.js +107 -0
  94. package/es/composite-comp/dito/components/CommonFunctions/mobile/index.less +30 -0
  95. package/es/composite-comp/dito/components/FlashDeal/mobile/index.js +8 -6
  96. package/es/composite-comp/dito/components/FlashDeal/mobile/index.less +83 -97
  97. package/es/composite-comp/dito/components/FlashDeal/pc/index.js +8 -6
  98. package/es/composite-comp/dito/components/HeadNavigation/defaultJSON.js +102 -0
  99. package/es/composite-comp/dito/components/HeadNavigation/index.js +84 -0
  100. package/es/composite-comp/dito/components/HeadNavigation/mobile/index.js +112 -0
  101. package/es/composite-comp/dito/components/HeadNavigation/mobile/index.less +34 -0
  102. package/es/composite-comp/dito/components/MenuNavigation/MenuNavMetaImage/index.js +206 -0
  103. package/es/composite-comp/dito/components/MenuNavigation/MenuNavMetaImage/index.less +25 -0
  104. package/es/composite-comp/dito/components/MenuNavigation/defaultJSON.js +107 -0
  105. package/es/composite-comp/dito/components/MenuNavigation/index.js +84 -0
  106. package/es/composite-comp/dito/components/MenuNavigation/mobile/index.js +87 -0
  107. package/es/composite-comp/dito/components/MenuNavigation/mobile/index.less +8 -0
  108. package/es/composite-comp/dito/components/MobileNavigation/mobile/index.less +18 -35
  109. package/es/composite-comp/dito/components/Orders/defaultJSON.js +89 -0
  110. package/es/composite-comp/dito/components/Orders/index.js +84 -0
  111. package/es/composite-comp/dito/components/Orders/mobile/index.js +345 -0
  112. package/es/composite-comp/dito/components/Orders/mobile/index.less +82 -0
  113. package/es/composite-comp/dito/components/PersonalInformation/defaultJSON.js +95 -0
  114. package/es/composite-comp/dito/components/PersonalInformation/index.js +84 -0
  115. package/es/composite-comp/dito/components/PersonalInformation/mobile/images/avatar.png +0 -0
  116. package/es/composite-comp/dito/components/PersonalInformation/mobile/index.js +587 -0
  117. package/es/composite-comp/dito/components/PersonalInformation/mobile/index.less +133 -0
  118. package/es/composite-comp/dito/components/Recommend/mobile/index.js +6 -5
  119. package/es/composite-comp/dito/components/Recommend/mobile/index.less +73 -86
  120. package/es/composite-comp/dito/components/Recommend/pc/index.js +6 -5
  121. package/es/composite-comp/dito/components/SearchBar/mobile/index.less +45 -52
  122. package/es/composite-comp/dito/components/SignBoard/mobile/index.js +6 -9
  123. package/es/composite-comp/dito/components/SignBoard/mobile/index.less +62 -66
  124. package/es/composite-comp/dito/config-panels/AffiliateRecommendConfig/RecommendConfigContent/index.js +102 -0
  125. package/es/composite-comp/dito/config-panels/AffiliateRecommendConfig/RecommendConfigContent/index.less +0 -0
  126. package/es/composite-comp/dito/config-panels/AffiliateRecommendConfig/RecommendConfigGroup/index.js +148 -0
  127. package/es/composite-comp/dito/config-panels/AffiliateRecommendConfig/RecommendConfigGroup/index.less +16 -0
  128. package/es/composite-comp/dito/config-panels/AffiliateRecommendConfig/imgs/defaultImg.png +0 -0
  129. package/es/composite-comp/dito/config-panels/AffiliateRecommendConfig/index.js +141 -0
  130. package/es/composite-comp/dito/config-panels/CommonFunctionsConfig/ConfigGroup/index.js +128 -0
  131. package/es/composite-comp/dito/config-panels/CommonFunctionsConfig/index.js +113 -0
  132. package/es/composite-comp/dito/config-panels/HeadNavigationConfig/GroupList/index.js +203 -0
  133. package/es/composite-comp/dito/config-panels/HeadNavigationConfig/GroupList/index.less +72 -0
  134. package/es/composite-comp/dito/config-panels/HeadNavigationConfig/HeadNavConfigImageGroup/index.js +142 -0
  135. package/es/composite-comp/dito/config-panels/HeadNavigationConfig/index.js +121 -0
  136. package/es/composite-comp/dito/config-panels/HeadNavigationConfig/index.less +23 -0
  137. package/es/composite-comp/dito/config-panels/MenuNavigationConfig/GroupList/index.js +203 -0
  138. package/es/composite-comp/dito/config-panels/MenuNavigationConfig/GroupList/index.less +72 -0
  139. package/es/composite-comp/dito/config-panels/MenuNavigationConfig/MenuNavConfigImageGroup/index.js +137 -0
  140. package/es/composite-comp/dito/config-panels/MenuNavigationConfig/MenuNavConfigImageGroup/index.less +6 -0
  141. package/es/composite-comp/dito/config-panels/MenuNavigationConfig/index.js +40 -0
  142. package/es/composite-comp/dito/config-panels/OrdersConfig/ConfigGroup/index.js +131 -0
  143. package/es/composite-comp/dito/config-panels/OrdersConfig/index.js +114 -0
  144. package/es/composite-comp/dito/config-panels/PersonalInformationConfig/ConfigGroup/index.js +131 -0
  145. package/es/composite-comp/dito/config-panels/PersonalInformationConfig/index.js +118 -0
  146. package/es/composite-comp/dito/config-panels/RecommendConfig/RecommendConfigGroup/index.js +10 -9
  147. package/es/composite-comp/dito/second-config-panels/AffiliateRecommendSecondConfig/AIRecommendation/index.js +431 -0
  148. package/es/composite-comp/dito/second-config-panels/AffiliateRecommendSecondConfig/index.js +214 -0
  149. package/es/composite-comp/dito/second-config-panels/AffiliateRecommendSecondConfig/index.less +15 -0
  150. package/es/composite-comp/dito/second-config-panels/CommonFunctionsSecondConfig/index.js +122 -0
  151. package/es/composite-comp/dito/second-config-panels/CommonFunctionsSecondConfig/index.less +0 -0
  152. package/es/composite-comp/dito/second-config-panels/HeadNavigationSecondConfig/index.js +127 -0
  153. package/es/composite-comp/dito/second-config-panels/MenuNavigationSecondConfig/index.js +127 -0
  154. package/es/composite-comp/dito/second-config-panels/OrdersSecondConfig/index.js +148 -0
  155. package/es/composite-comp/dito/second-config-panels/OrdersSecondConfig/index.less +9 -0
  156. package/es/composite-comp/dito/second-config-panels/PersonalInformationSecondConfig/index.js +143 -0
  157. package/es/composite-comp/dito/second-config-panels/PersonalInformationSecondConfig/index.less +9 -0
  158. package/es/constants/component-types.js +45 -3
  159. package/es/constants/index.js +74 -5
  160. package/es/constants/layout.js +48 -1
  161. package/es/core/Designer/ChatRobot/components/SearchCondition/index.js +128 -0
  162. package/es/core/Designer/ChatRobot/components/SearchCondition/index.less +33 -0
  163. package/es/core/Designer/ChatRobot/index.js +84 -17
  164. package/es/core/Designer/ChatRobot/index.less +69 -28
  165. package/es/core/Designer/ConfigPanel/index.js +14 -3
  166. package/es/core/Designer/FonixtreeGpt/index.js +222 -29
  167. package/es/core/Designer/PageCompList/index.js +6 -5
  168. package/es/core/Designer/QuickMenuBar/index.js +11 -5
  169. package/es/core/Designer/QuickMenuBar/index.less +4 -0
  170. package/es/core/Designer/RenderHtml/index.js +18 -15
  171. package/es/core/Designer/RenderHtml/index.less +1 -1
  172. package/es/core/Designer/ToolBarModal/ToolBtn/components/AlignPicker/images/AlignCenterSVG.js +19 -6
  173. package/es/core/Designer/ToolBarModal/ToolBtn/components/AlignPicker/images/AlignLeftSVG.js +19 -6
  174. package/es/core/Designer/ToolBarModal/ToolBtn/components/AlignPicker/images/AlignRightSVG.js +19 -6
  175. package/es/core/Designer/ToolBarModal/ToolBtn/components/BulletPicker/index.js +27 -6
  176. package/es/core/Designer/ToolBarModal/ToolBtn/components/BulletPicker/index.less +4 -20
  177. package/es/core/Designer/ToolBarModal/ToolBtn/components/ColorPickerBtn/UnderlineSelectPicker/index.js +77 -0
  178. package/es/core/Designer/ToolBarModal/ToolBtn/components/ColorPickerBtn/UnderlineSelectPicker/index.less +27 -0
  179. package/es/core/Designer/ToolBarModal/ToolBtn/components/ColorPickerBtn/index.js +36 -5
  180. package/es/core/Designer/ToolBarModal/ToolBtn/components/ColorPickerBtn/index.less +17 -16
  181. package/es/core/Designer/ToolBarModal/ToolBtn/components/OrderedPicker/index.js +27 -6
  182. package/es/core/Designer/ToolBarModal/ToolBtn/components/OrderedPicker/index.less +4 -20
  183. package/es/core/Designer/ToolBarModal/ToolBtn/images/AlignCenterSVG.js +40 -0
  184. package/es/core/Designer/ToolBarModal/ToolBtn/images/AlignLeftSVG.js +40 -0
  185. package/es/core/Designer/ToolBarModal/ToolBtn/images/AlignRightSVG.js +40 -0
  186. package/es/core/Designer/ToolBarModal/ToolBtn/index.js +28 -3
  187. package/es/core/Designer/ToolBarModal/ToolBtn/index.less +2 -1
  188. package/es/core/Designer/ToolBarModal/index.js +68 -22
  189. package/es/core/Designer/ToolBarModal/index.less +3 -2
  190. package/es/core/Designer/index.js +26 -2
  191. package/es/core/Renderer/index.js +76 -29
  192. package/es/decorator/compositeDecorator.js +33 -6
  193. package/es/decorator/metaDecorator.js +1 -1
  194. package/es/locale/en/en.json +17 -3
  195. package/es/locale/es/es.json +17 -3
  196. package/es/locale/id/id.json +17 -3
  197. package/es/meta-comp/components/Image/index.js +31 -25
  198. package/es/meta-comp/components/Text/formats/textAlign.js +58 -0
  199. package/es/meta-comp/components/Text/index.js +4 -1
  200. package/es/meta-comp/components/Text/index.less +8 -0
  201. package/es/meta-comp/config-panels/ImageConfig/index.js +48 -44
  202. package/es/mobx/Frame.js +17 -2
  203. package/es/mobx/UserState.js +144 -0
  204. package/es/mobx/index.js +9 -3
  205. package/es/utils/androidUtil.js +13 -2
  206. package/es/utils/businessUtil.js +25 -3
  207. package/es/utils/commonUtil.js +177 -22
  208. package/es/utils/coreUtil.js +45 -2
  209. package/es/utils/currencyUtil.js +9 -2
  210. package/lib/assets/fonts/.DS_Store +0 -0
  211. package/lib/assets/fonts/Trueno-Light.otf +0 -0
  212. package/lib/assets/fonts/Trueno-Regular.otf +0 -0
  213. package/lib/assets/fonts/TruenoBd.otf +0 -0
  214. package/lib/assets/fonts/magic-box-iconfont.css +62 -6
  215. package/lib/assets/fonts/magic-box-iconfont.css.bak +35 -3
  216. package/lib/assets/fonts/magic-box-iconfont.js +1 -1
  217. package/lib/assets/fonts/magic-box-iconfont.js.bak +1 -1
  218. package/lib/assets/fonts/magic-box-iconfont.ttf +0 -0
  219. package/lib/assets/fonts/magic-box-iconfont.woff +0 -0
  220. package/lib/assets/fonts/magic-box-iconfont.woff2 +0 -0
  221. package/lib/assets/images/base64/index.js +36 -2
  222. package/lib/assets/images/layout-icon/walletLayout2.png +0 -0
  223. package/lib/assets/images/layout-icon/walletNuriLayout1.png +0 -0
  224. package/lib/assets/less/button.less +5 -0
  225. package/lib/assets/less/cylon-antd.less +7246 -1686
  226. package/lib/assets/less/font.less +22 -0
  227. package/lib/common/AffiliateProductModal/index.js +582 -0
  228. package/lib/common/AffiliateProductModal/index.less +146 -0
  229. package/lib/common/Button/index.less +0 -1
  230. package/lib/common/CardCarousel/index.js +171 -0
  231. package/lib/common/CardCarousel/index.less +28 -0
  232. package/lib/common/CountDown/index.js +20 -11
  233. package/lib/common/CropperModal/index.js +126 -0
  234. package/lib/common/CropperModal/index.less +29 -0
  235. package/lib/common/GroupList/index.js +7 -2
  236. package/lib/common/ImagePicker/index.js +1 -3
  237. package/lib/common/LinkModal/CouponTable/index.js +3 -3
  238. package/lib/common/LinkModal/CustomTable/index.js +1 -0
  239. package/lib/common/LinkModal/FunctionTable/index.js +2 -1
  240. package/lib/common/LinkModal/index.js +14 -2
  241. package/lib/common/MagicLink/index.js +2 -2
  242. package/lib/common/MyModal/index.js +417 -0
  243. package/lib/common/MyModal/index.less +74 -0
  244. package/lib/common/ProductModal/index.js +38 -3
  245. package/lib/common/ProductSource/index.js +59 -18
  246. package/lib/common/UrlPicker/AnchorModal/index.js +170 -0
  247. package/lib/common/UrlPicker/AnchorModal/index.less +21 -0
  248. package/lib/common/UrlPicker/index.js +52 -9
  249. package/lib/common/index.js +24 -0
  250. package/lib/composite-comp/bol/components/Banner/mobile/index.js +1 -2
  251. package/lib/composite-comp/bol/components/Banner/mobile/index.less +52 -78
  252. package/lib/composite-comp/bol/components/Carousel/mobile/index.less +81 -100
  253. package/lib/composite-comp/bol/components/ImageGallery/mobile/index.less +15 -22
  254. package/lib/composite-comp/bol/components/ImageText/mobile/index.less +233 -292
  255. package/lib/composite-comp/bol/components/Video/index.js +1 -2
  256. package/lib/composite-comp/bol/components/Video/mobile/Layout1/index.less +21 -27
  257. package/lib/composite-comp/bol/components/Video/mobile/Layout2/index.less +36 -45
  258. package/lib/composite-comp/bol/components/Video/mobile/Layout3/index.less +43 -54
  259. package/lib/composite-comp/bol/components/Video/mobile/index.less +2 -3
  260. package/lib/composite-comp/bol/components/Wallet/defaultJSON.js +112 -88
  261. package/lib/composite-comp/bol/components/Wallet/index.js +11 -15
  262. package/lib/composite-comp/bol/components/Wallet/mobile/index.js +314 -64
  263. package/lib/composite-comp/bol/components/Wallet/mobile/index.less +103 -40
  264. package/lib/composite-comp/bol/components/Wallet/pc/index.js +0 -2
  265. package/lib/composite-comp/bol/components/Wallet/pc/index.less +1 -40
  266. package/lib/composite-comp/bol/components/WalletNuri/defaultJSON.js +148 -0
  267. package/lib/composite-comp/bol/components/WalletNuri/index.js +84 -0
  268. package/lib/composite-comp/bol/components/WalletNuri/mobile/index.js +366 -0
  269. package/lib/composite-comp/bol/components/WalletNuri/mobile/index.less +22 -0
  270. package/lib/composite-comp/bol/config-panels/WalletConfig/WalletConfigImageGroup/index.js +1 -6
  271. package/lib/composite-comp/bol/config-panels/WalletConfig/WalletConfigSetting/index.js +201 -0
  272. package/lib/composite-comp/bol/config-panels/WalletConfig/WalletConfigSetting/index.less +9 -0
  273. package/lib/composite-comp/bol/config-panels/WalletConfig/index.js +11 -2
  274. package/lib/composite-comp/bol/config-panels/WalletNuriConfig/GroupList/defaultImg.png +0 -0
  275. package/lib/composite-comp/bol/config-panels/WalletNuriConfig/GroupList/index.js +100 -0
  276. package/lib/composite-comp/bol/config-panels/WalletNuriConfig/GroupList/index.less +72 -0
  277. package/lib/composite-comp/bol/config-panels/WalletNuriConfig/WalletNuriConfigImageGroup/index.js +123 -0
  278. package/lib/composite-comp/bol/config-panels/WalletNuriConfig/WalletNuriConfigImageGroup/index.less +0 -0
  279. package/lib/composite-comp/bol/config-panels/WalletNuriConfig/imgs/defaultImg.png +0 -0
  280. package/lib/composite-comp/bol/config-panels/WalletNuriConfig/index.js +61 -0
  281. package/lib/composite-comp/bol/second-config-panels/ImageTextSecondConfig/index.js +2 -2
  282. package/lib/composite-comp/bol/second-config-panels/WalletNuriSecondConfig/index.js +152 -0
  283. package/lib/composite-comp/bol/second-config-panels/WalletSecondConfig/index.js +58 -82
  284. package/lib/composite-comp/bol/second-config-panels/WalletSecondConfig/index.less +2 -0
  285. package/lib/composite-comp/common/components/AffiliateProductItem/imgs/icon-Balance2.svg +9 -0
  286. package/lib/composite-comp/common/components/AffiliateProductItem/imgs/icon-Koin.svg +40 -0
  287. package/lib/composite-comp/common/components/AffiliateProductItem/index.js +168 -0
  288. package/lib/composite-comp/common/components/AffiliateProductItem/index.less +129 -0
  289. package/lib/composite-comp/common/components/ProductItem/index.js +22 -20
  290. package/lib/composite-comp/common/components/ProductItem/index.less +2 -12
  291. package/lib/composite-comp/common/config-panels/CustomizeConfig/index.js +13 -0
  292. package/lib/composite-comp/common/config-panels/CustomizeConfig/index.less +3 -2
  293. package/lib/composite-comp/common/config-panels/SpacingConfig/index.js +1 -0
  294. package/lib/composite-comp/dito/components/AffiliateRecommend/defaultJSON.js +243 -0
  295. package/lib/composite-comp/dito/components/AffiliateRecommend/index.js +90 -0
  296. package/lib/composite-comp/dito/components/AffiliateRecommend/mobile/index.js +660 -0
  297. package/lib/composite-comp/dito/components/AffiliateRecommend/mobile/index.less +84 -0
  298. package/lib/composite-comp/dito/components/AffiliateRecommend/pc/index.js +728 -0
  299. package/lib/composite-comp/dito/components/AffiliateRecommend/pc/index.less +124 -0
  300. package/lib/composite-comp/dito/components/CommonFunctions/defaultJSON.js +92 -0
  301. package/lib/composite-comp/dito/components/CommonFunctions/index.js +84 -0
  302. package/lib/composite-comp/dito/components/CommonFunctions/mobile/index.js +107 -0
  303. package/lib/composite-comp/dito/components/CommonFunctions/mobile/index.less +30 -0
  304. package/lib/composite-comp/dito/components/FlashDeal/mobile/index.js +8 -6
  305. package/lib/composite-comp/dito/components/FlashDeal/mobile/index.less +83 -97
  306. package/lib/composite-comp/dito/components/FlashDeal/pc/index.js +8 -6
  307. package/lib/composite-comp/dito/components/HeadNavigation/defaultJSON.js +102 -0
  308. package/lib/composite-comp/dito/components/HeadNavigation/index.js +84 -0
  309. package/lib/composite-comp/dito/components/HeadNavigation/mobile/index.js +112 -0
  310. package/lib/composite-comp/dito/components/HeadNavigation/mobile/index.less +34 -0
  311. package/lib/composite-comp/dito/components/MenuNavigation/MenuNavMetaImage/index.js +206 -0
  312. package/lib/composite-comp/dito/components/MenuNavigation/MenuNavMetaImage/index.less +25 -0
  313. package/lib/composite-comp/dito/components/MenuNavigation/defaultJSON.js +107 -0
  314. package/lib/composite-comp/dito/components/MenuNavigation/index.js +84 -0
  315. package/lib/composite-comp/dito/components/MenuNavigation/mobile/index.js +87 -0
  316. package/lib/composite-comp/dito/components/MenuNavigation/mobile/index.less +8 -0
  317. package/lib/composite-comp/dito/components/MobileNavigation/mobile/index.less +18 -35
  318. package/lib/composite-comp/dito/components/Orders/defaultJSON.js +89 -0
  319. package/lib/composite-comp/dito/components/Orders/index.js +84 -0
  320. package/lib/composite-comp/dito/components/Orders/mobile/index.js +345 -0
  321. package/lib/composite-comp/dito/components/Orders/mobile/index.less +82 -0
  322. package/lib/composite-comp/dito/components/PersonalInformation/defaultJSON.js +95 -0
  323. package/lib/composite-comp/dito/components/PersonalInformation/index.js +84 -0
  324. package/lib/composite-comp/dito/components/PersonalInformation/mobile/images/avatar.png +0 -0
  325. package/lib/composite-comp/dito/components/PersonalInformation/mobile/index.js +587 -0
  326. package/lib/composite-comp/dito/components/PersonalInformation/mobile/index.less +133 -0
  327. package/lib/composite-comp/dito/components/Recommend/mobile/index.js +6 -5
  328. package/lib/composite-comp/dito/components/Recommend/mobile/index.less +73 -86
  329. package/lib/composite-comp/dito/components/Recommend/pc/index.js +6 -5
  330. package/lib/composite-comp/dito/components/SearchBar/mobile/index.less +45 -52
  331. package/lib/composite-comp/dito/components/SignBoard/mobile/index.js +6 -9
  332. package/lib/composite-comp/dito/components/SignBoard/mobile/index.less +62 -66
  333. package/lib/composite-comp/dito/config-panels/AffiliateRecommendConfig/RecommendConfigContent/index.js +102 -0
  334. package/lib/composite-comp/dito/config-panels/AffiliateRecommendConfig/RecommendConfigContent/index.less +0 -0
  335. package/lib/composite-comp/dito/config-panels/AffiliateRecommendConfig/RecommendConfigGroup/index.js +148 -0
  336. package/lib/composite-comp/dito/config-panels/AffiliateRecommendConfig/RecommendConfigGroup/index.less +16 -0
  337. package/lib/composite-comp/dito/config-panels/AffiliateRecommendConfig/imgs/defaultImg.png +0 -0
  338. package/lib/composite-comp/dito/config-panels/AffiliateRecommendConfig/index.js +141 -0
  339. package/lib/composite-comp/dito/config-panels/CommonFunctionsConfig/ConfigGroup/index.js +128 -0
  340. package/lib/composite-comp/dito/config-panels/CommonFunctionsConfig/index.js +113 -0
  341. package/lib/composite-comp/dito/config-panels/HeadNavigationConfig/GroupList/index.js +203 -0
  342. package/lib/composite-comp/dito/config-panels/HeadNavigationConfig/GroupList/index.less +72 -0
  343. package/lib/composite-comp/dito/config-panels/HeadNavigationConfig/HeadNavConfigImageGroup/index.js +142 -0
  344. package/lib/composite-comp/dito/config-panels/HeadNavigationConfig/index.js +121 -0
  345. package/lib/composite-comp/dito/config-panels/HeadNavigationConfig/index.less +23 -0
  346. package/lib/composite-comp/dito/config-panels/MenuNavigationConfig/GroupList/index.js +203 -0
  347. package/lib/composite-comp/dito/config-panels/MenuNavigationConfig/GroupList/index.less +72 -0
  348. package/lib/composite-comp/dito/config-panels/MenuNavigationConfig/MenuNavConfigImageGroup/index.js +137 -0
  349. package/lib/composite-comp/dito/config-panels/MenuNavigationConfig/MenuNavConfigImageGroup/index.less +6 -0
  350. package/lib/composite-comp/dito/config-panels/MenuNavigationConfig/index.js +40 -0
  351. package/lib/composite-comp/dito/config-panels/OrdersConfig/ConfigGroup/index.js +131 -0
  352. package/lib/composite-comp/dito/config-panels/OrdersConfig/index.js +114 -0
  353. package/lib/composite-comp/dito/config-panels/PersonalInformationConfig/ConfigGroup/index.js +131 -0
  354. package/lib/composite-comp/dito/config-panels/PersonalInformationConfig/index.js +118 -0
  355. package/lib/composite-comp/dito/config-panels/RecommendConfig/RecommendConfigGroup/index.js +10 -9
  356. package/lib/composite-comp/dito/second-config-panels/AffiliateRecommendSecondConfig/AIRecommendation/index.js +431 -0
  357. package/lib/composite-comp/dito/second-config-panels/AffiliateRecommendSecondConfig/index.js +214 -0
  358. package/lib/composite-comp/dito/second-config-panels/AffiliateRecommendSecondConfig/index.less +15 -0
  359. package/lib/composite-comp/dito/second-config-panels/CommonFunctionsSecondConfig/index.js +122 -0
  360. package/lib/composite-comp/dito/second-config-panels/CommonFunctionsSecondConfig/index.less +0 -0
  361. package/lib/composite-comp/dito/second-config-panels/HeadNavigationSecondConfig/index.js +127 -0
  362. package/lib/composite-comp/dito/second-config-panels/MenuNavigationSecondConfig/index.js +127 -0
  363. package/lib/composite-comp/dito/second-config-panels/OrdersSecondConfig/index.js +148 -0
  364. package/lib/composite-comp/dito/second-config-panels/OrdersSecondConfig/index.less +9 -0
  365. package/lib/composite-comp/dito/second-config-panels/PersonalInformationSecondConfig/index.js +143 -0
  366. package/lib/composite-comp/dito/second-config-panels/PersonalInformationSecondConfig/index.less +9 -0
  367. package/lib/constants/component-types.js +45 -3
  368. package/lib/constants/index.js +74 -5
  369. package/lib/constants/layout.js +48 -1
  370. package/lib/core/Designer/ChatRobot/components/SearchCondition/index.js +128 -0
  371. package/lib/core/Designer/ChatRobot/components/SearchCondition/index.less +33 -0
  372. package/lib/core/Designer/ChatRobot/index.js +84 -17
  373. package/lib/core/Designer/ChatRobot/index.less +69 -28
  374. package/lib/core/Designer/ConfigPanel/index.js +14 -3
  375. package/lib/core/Designer/FonixtreeGpt/index.js +222 -29
  376. package/lib/core/Designer/PageCompList/index.js +6 -5
  377. package/lib/core/Designer/QuickMenuBar/index.js +11 -5
  378. package/lib/core/Designer/QuickMenuBar/index.less +4 -0
  379. package/lib/core/Designer/RenderHtml/index.js +18 -15
  380. package/lib/core/Designer/RenderHtml/index.less +1 -1
  381. package/lib/core/Designer/ToolBarModal/ToolBtn/components/AlignPicker/images/AlignCenterSVG.js +19 -6
  382. package/lib/core/Designer/ToolBarModal/ToolBtn/components/AlignPicker/images/AlignLeftSVG.js +19 -6
  383. package/lib/core/Designer/ToolBarModal/ToolBtn/components/AlignPicker/images/AlignRightSVG.js +19 -6
  384. package/lib/core/Designer/ToolBarModal/ToolBtn/components/BulletPicker/index.js +27 -6
  385. package/lib/core/Designer/ToolBarModal/ToolBtn/components/BulletPicker/index.less +4 -20
  386. package/lib/core/Designer/ToolBarModal/ToolBtn/components/ColorPickerBtn/UnderlineSelectPicker/index.js +77 -0
  387. package/lib/core/Designer/ToolBarModal/ToolBtn/components/ColorPickerBtn/UnderlineSelectPicker/index.less +27 -0
  388. package/lib/core/Designer/ToolBarModal/ToolBtn/components/ColorPickerBtn/index.js +36 -5
  389. package/lib/core/Designer/ToolBarModal/ToolBtn/components/ColorPickerBtn/index.less +17 -16
  390. package/lib/core/Designer/ToolBarModal/ToolBtn/components/OrderedPicker/index.js +27 -6
  391. package/lib/core/Designer/ToolBarModal/ToolBtn/components/OrderedPicker/index.less +4 -20
  392. package/lib/core/Designer/ToolBarModal/ToolBtn/images/AlignCenterSVG.js +40 -0
  393. package/lib/core/Designer/ToolBarModal/ToolBtn/images/AlignLeftSVG.js +40 -0
  394. package/lib/core/Designer/ToolBarModal/ToolBtn/images/AlignRightSVG.js +40 -0
  395. package/lib/core/Designer/ToolBarModal/ToolBtn/index.js +28 -3
  396. package/lib/core/Designer/ToolBarModal/ToolBtn/index.less +2 -1
  397. package/lib/core/Designer/ToolBarModal/index.js +68 -22
  398. package/lib/core/Designer/ToolBarModal/index.less +3 -2
  399. package/lib/core/Designer/index.js +26 -2
  400. package/lib/core/Renderer/index.js +76 -29
  401. package/lib/decorator/compositeDecorator.js +33 -6
  402. package/lib/decorator/metaDecorator.js +1 -1
  403. package/lib/locale/en/en.json +17 -3
  404. package/lib/locale/es/es.json +17 -3
  405. package/lib/locale/id/id.json +17 -3
  406. package/lib/meta-comp/components/Image/index.js +31 -25
  407. package/lib/meta-comp/components/Text/formats/textAlign.js +58 -0
  408. package/lib/meta-comp/components/Text/index.js +4 -1
  409. package/lib/meta-comp/components/Text/index.less +8 -0
  410. package/lib/meta-comp/config-panels/ImageConfig/index.js +48 -44
  411. package/lib/mobx/Frame.js +17 -2
  412. package/lib/mobx/UserState.js +144 -0
  413. package/lib/mobx/index.js +9 -3
  414. package/lib/utils/androidUtil.js +13 -2
  415. package/lib/utils/businessUtil.js +25 -3
  416. package/lib/utils/commonUtil.js +177 -22
  417. package/lib/utils/coreUtil.js +45 -2
  418. package/lib/utils/currencyUtil.js +9 -2
  419. package/package.json +2 -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
+
@@ -310,13 +310,17 @@ var ProductModal = function ProductModal(props) {
310
310
  selectedList = _w[0],
311
311
  setSelectedList = _w[1];
312
312
 
313
- var _x = (0, _react.useState)({
313
+ var _x = (0, _react.useState)(''),
314
+ dragId = _x[0],
315
+ setDragId = _x[1];
316
+
317
+ var _y = (0, _react.useState)({
314
318
  pageSize: 20,
315
319
  current: 1,
316
320
  total: 0
317
321
  }),
318
- paginationParams = _x[0],
319
- setPaginationParams = _x[1];
322
+ paginationParams = _y[0],
323
+ setPaginationParams = _y[1];
320
324
 
321
325
  var rowSelection = {
322
326
  selectedRowKeys: selectedList.map(function (v) {
@@ -344,8 +348,39 @@ var ProductModal = function ProductModal(props) {
344
348
  name: record.name
345
349
  };
346
350
  }
351
+ };
352
+
353
+ var moveItem = function moveItem(dragNodeId, hoverNodeId) {
354
+ var source = JSON.parse(JSON.stringify(selectedList));
355
+ var dragIndex = source.findIndex(function (obj) {
356
+ return obj.productId == dragNodeId;
357
+ });
358
+ var hoverIndex = source.findIndex(function (obj) {
359
+ return obj.productId == hoverNodeId;
360
+ });
361
+ var list = dragSource(source, dragIndex, hoverIndex);
362
+ setSelectedList(list);
363
+ };
364
+
365
+ var onDragStart = function onDragStart(e) {
366
+ setDragId(e.currentTarget.dataset.nodeid);
367
+ };
368
+
369
+ var onDragEnter = function onDragEnter(e) {
370
+ var hoverNodeId = e.currentTarget.dataset.nodeid;
371
+
372
+ if (dragId === hoverNodeId) {
373
+ return;
374
+ }
375
+
376
+ moveItem(dragId, hoverNodeId);
377
+ };
378
+
379
+ var onDragEnd = function onDragEnd() {
380
+ setDragId('');
347
381
  }; // 请求商品列表
348
382
 
383
+
349
384
  var queryGoods = function queryGoods() {
350
385
  return __awaiter(void 0, void 0, void 0, function () {
351
386
  var _list, total, params, res_1, res;
@@ -19,6 +19,8 @@ var _ProductModal = _interopRequireWildcard(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); }
@@ -189,6 +191,7 @@ function ProductSource(_a) {
189
191
 
190
192
  var value = _a.value,
191
193
  onChange = _a.onChange,
194
+ isAffiliate = _a.isAffiliate,
192
195
  prodType = _a.prodType;
193
196
 
194
197
  var _b = (0, _react.useState)([]),
@@ -201,16 +204,37 @@ function ProductSource(_a) {
201
204
 
202
205
  var onSelectProduct = function onSelectProduct() {
203
206
  return __awaiter(_this, void 0, void 0, function () {
204
- var url, param, list_1, url, param, list;
207
+ var url, param, list, url, param, list_1, url, param, list;
205
208
  return __generator(this, function (_a) {
206
209
  switch (_a.label) {
207
210
  case 0:
208
211
  if (!(value && value.length > 0)) return [3
209
212
  /*break*/
210
- , 5];
211
- if (!(prodType === 'spu')) return [3
213
+ , 7];
214
+ if (!isAffiliate) return [3
212
215
  /*break*/
213
216
  , 2];
217
+ url = "/designer/v1/" + window.magicDesign.MBaseUrl + "/distributor/product/list";
218
+ param = {
219
+ affiliateProductIds: value,
220
+ pageSize: value.length,
221
+ pageIndex: 1
222
+ };
223
+ return [4
224
+ /*yield*/
225
+ , (0, _commonUtil.commonFetch)(url, param, 'GET')];
226
+
227
+ case 1:
228
+ list = _a.sent().list;
229
+ setSelectedProds(list || []);
230
+ return [3
231
+ /*break*/
232
+ , 6];
233
+
234
+ case 2:
235
+ if (!(prodType === 'spu')) return [3
236
+ /*break*/
237
+ , 4];
214
238
  url = "/designer/v1/" + window.magicDesign.MBaseUrl + "/offers";
215
239
  param = {
216
240
  offers: value,
@@ -223,7 +247,7 @@ function ProductSource(_a) {
223
247
  /*yield*/
224
248
  , (0, _commonUtil.commonFetch)(url, param, 'GET')];
225
249
 
226
- case 1:
250
+ case 3:
227
251
  list_1 = _a.sent().list;
228
252
  setSelectedProds((0, _ProductModal.formatData)((0, _commonUtil.ensure)(function () {
229
253
  return list_1.map(function (m) {
@@ -232,9 +256,9 @@ function ProductSource(_a) {
232
256
  }, []), prodType));
233
257
  return [3
234
258
  /*break*/
235
- , 4];
259
+ , 6];
236
260
 
237
- case 2:
261
+ case 4:
238
262
  url = "/designer/v1/" + window.magicDesign.MBaseUrl + "/products";
239
263
  param = {
240
264
  products: value,
@@ -244,21 +268,21 @@ function ProductSource(_a) {
244
268
  /*yield*/
245
269
  , (0, _commonUtil.commonFetch)(url, param, 'GET')];
246
270
 
247
- case 3:
271
+ case 5:
248
272
  list = _a.sent().list;
249
273
  setSelectedProds((0, _ProductModal.formatData)(list || []));
250
- _a.label = 4;
274
+ _a.label = 6;
251
275
 
252
- case 4:
276
+ case 6:
253
277
  return [3
254
278
  /*break*/
255
- , 6];
279
+ , 8];
256
280
 
257
- case 5:
281
+ case 7:
258
282
  setSelectedProds([]);
259
- _a.label = 6;
283
+ _a.label = 8;
260
284
 
261
- case 6:
285
+ case 8:
262
286
  setVisbile(true);
263
287
  return [2
264
288
  /*return*/
@@ -269,9 +293,18 @@ function ProductSource(_a) {
269
293
  };
270
294
 
271
295
  var handleModalSave = function handleModalSave(list, type) {
272
- var ids = list.map(function (prod) {
273
- return prod.id;
274
- }).join(',');
296
+ var ids = '';
297
+
298
+ if (isAffiliate) {
299
+ ids = list.map(function (prod) {
300
+ return prod.affiliateProductId;
301
+ }).join(',');
302
+ } else {
303
+ ids = list.map(function (prod) {
304
+ return prod.id;
305
+ }).join(',');
306
+ }
307
+
275
308
  onChange(ids, type);
276
309
  };
277
310
 
@@ -292,7 +325,15 @@ function ProductSource(_a) {
292
325
  className: "total"
293
326
  }, (0, _locale.i18n)('TOTAL_PRODUCTS', {
294
327
  count: getLength()
295
- })), visible && /*#__PURE__*/_react["default"].createElement(_ProductModal["default"], {
328
+ })), visible && (isAffiliate ? /*#__PURE__*/_react["default"].createElement(_AffiliateProductModal["default"], {
329
+ closeModal: function closeModal() {
330
+ return setVisbile(false);
331
+ },
332
+ defaultList: selectedProds,
333
+ handleModalSave: handleModalSave,
334
+ maxSelect: 100,
335
+ visible: visible
336
+ }) : /*#__PURE__*/_react["default"].createElement(_ProductModal["default"], {
296
337
  closeModal: function closeModal() {
297
338
  return setVisbile(false);
298
339
  },
@@ -301,5 +342,5 @@ function ProductSource(_a) {
301
342
  maxSelect: 100,
302
343
  prodType: prodType,
303
344
  visible: visible
304
- }));
345
+ })));
305
346
  }