@gem-sdk/core 1.63.17 → 2.0.0-dev.156

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 (212) hide show
  1. package/dist/cjs/components/AddOn.js +1 -0
  2. package/dist/cjs/components/ComponentAnimation.js +1 -0
  3. package/dist/cjs/components/ComponentToolbarPreview.js +8 -7
  4. package/dist/cjs/components/ComponentWrapper.js +1 -0
  5. package/dist/cjs/components/ComponentWrapperPreview.js +3 -2
  6. package/dist/cjs/components/Empty.js +1 -0
  7. package/dist/cjs/components/InteractionSuffix.js +7 -6
  8. package/dist/cjs/components/Render.js +1 -0
  9. package/dist/cjs/components/Render.liquid.js +4 -1
  10. package/dist/cjs/components/RenderBlock.js +1 -0
  11. package/dist/cjs/components/RenderCustomCode.js +8 -7
  12. package/dist/cjs/components/RenderPreview.js +1 -0
  13. package/dist/cjs/components/RenderSection.js +1 -0
  14. package/dist/cjs/components/ai-generator/AIContentGenerator.js +5 -4
  15. package/dist/cjs/components/ai-generator/AIGenContentLoading.js +1 -0
  16. package/dist/cjs/components/ai-generator/components/PickProduct.js +5 -4
  17. package/dist/cjs/components/ai-generator/components/ToneAndVoice.js +1 -0
  18. package/dist/cjs/components/ai-generator/icons/AIIcon.js +1 -0
  19. package/dist/cjs/components/ai-generator/icons/CloseIcon.js +1 -0
  20. package/dist/cjs/components/ai-generator/icons/DropdownIcon.js +1 -0
  21. package/dist/cjs/components/ai-generator/icons/SearchIcon.js +1 -0
  22. package/dist/cjs/components/ai-generator/icons/ShowMoreIcon.js +1 -0
  23. package/dist/cjs/components/ai-generator/icons/UpgradeIcon.js +1 -0
  24. package/dist/cjs/components/ai-generator/icons/WarningIcon.js +1 -0
  25. package/dist/cjs/components/resize/Resize.js +1 -0
  26. package/dist/cjs/components/resize/Spacing.js +8 -7
  27. package/dist/cjs/components/theme-section/CreateThemeSection.js +5 -4
  28. package/dist/cjs/components/theme-section/ThemeSectionStatus.js +1 -0
  29. package/dist/cjs/components/theme-section/ThemeSectionTooltip.js +1 -0
  30. package/dist/cjs/components/toolbar/Tooltip.js +1 -0
  31. package/dist/cjs/contexts/AddonContext.js +1 -0
  32. package/dist/cjs/contexts/ArticleContext.js +1 -0
  33. package/dist/cjs/contexts/ArticleListContext.js +1 -0
  34. package/dist/cjs/contexts/BuilderComponent.js +1 -0
  35. package/dist/cjs/contexts/BuilderContext.js +1 -0
  36. package/dist/cjs/contexts/BuilderPreviewContext.js +1 -0
  37. package/dist/cjs/contexts/CartLineContext.js +1 -0
  38. package/dist/cjs/contexts/CollectionContext.js +1 -0
  39. package/dist/cjs/contexts/ModalContext.js +1 -0
  40. package/dist/cjs/contexts/PageContext.js +1 -0
  41. package/dist/cjs/contexts/ProductContext.js +12 -12
  42. package/dist/cjs/contexts/ProductListContext.js +1 -0
  43. package/dist/cjs/contexts/SectionContext.js +1 -0
  44. package/dist/cjs/contexts/ShopContext.js +1 -0
  45. package/dist/cjs/graphql/fragments/preview-theme-page.generated.js +0 -4
  46. package/dist/cjs/graphql/fragments/published-theme-page.generated.js +4 -0
  47. package/dist/cjs/graphql/queries/articles.generated.js +1 -0
  48. package/dist/cjs/graphql/queries/blogs.generated.js +1 -0
  49. package/dist/cjs/graphql/queries/shop-shopify.generated.js +11 -0
  50. package/dist/cjs/helpers/align.js +18 -0
  51. package/dist/cjs/helpers/background.js +6 -2
  52. package/dist/cjs/helpers/backgroundImage.js +184 -0
  53. package/dist/cjs/helpers/borders.js +17 -0
  54. package/dist/cjs/helpers/compose-advance-style.js +71 -1
  55. package/dist/cjs/helpers/filter-toolbar-preview.js +1 -0
  56. package/dist/cjs/helpers/interaction/index.js +7 -6
  57. package/dist/cjs/helpers/is-empty-children.js +1 -0
  58. package/dist/cjs/helpers/layout.js +17 -0
  59. package/dist/cjs/helpers/radius.js +13 -1
  60. package/dist/cjs/helpers/shadow.js +28 -2
  61. package/dist/cjs/helpers/size.js +22 -0
  62. package/dist/cjs/helpers/third-party/appConfig.js +63 -0
  63. package/dist/cjs/helpers/third-party/appSetting.js +187 -6
  64. package/dist/cjs/helpers/third-party/constant.js +10 -1
  65. package/dist/cjs/helpers/typography.js +10 -1
  66. package/dist/cjs/hooks/animation/useAnimationActions.js +1 -0
  67. package/dist/cjs/hooks/animation/useAnimationConfig.js +1 -0
  68. package/dist/cjs/hooks/animation/useAnimationPreview.js +1 -0
  69. package/dist/cjs/hooks/animation/useAnimationTarget.js +1 -0
  70. package/dist/cjs/hooks/animation/useApplyAnimation.js +1 -0
  71. package/dist/cjs/hooks/articles/useArticlesQuery.js +1 -0
  72. package/dist/cjs/hooks/cart/use-add-to-cart.js +1 -0
  73. package/dist/cjs/hooks/cart/use-cart-data.js +1 -0
  74. package/dist/cjs/hooks/cart/use-cart-discount-codes-update.js +1 -0
  75. package/dist/cjs/hooks/cart/use-cart-note-update.js +1 -0
  76. package/dist/cjs/hooks/cart/use-create-cart.js +1 -0
  77. package/dist/cjs/hooks/cart/use-remove-cart-item.js +1 -0
  78. package/dist/cjs/hooks/cart/use-update-cart-item.js +1 -0
  79. package/dist/cjs/hooks/shop/use-collection-query.js +1 -0
  80. package/dist/cjs/hooks/shop/use-collections-query.js +1 -0
  81. package/dist/cjs/hooks/shop/use-product-query.js +1 -0
  82. package/dist/cjs/hooks/shop/use-products-query.js +1 -0
  83. package/dist/cjs/hooks/shop/useShopifyLink.js +47 -0
  84. package/dist/cjs/hooks/shop.js +10 -0
  85. package/dist/cjs/hooks/use-current-device.js +2 -1
  86. package/dist/cjs/hooks/use-lazy-video.js +1 -0
  87. package/dist/cjs/hooks/useAnimations.js +1 -0
  88. package/dist/cjs/hooks/useCartId.js +1 -0
  89. package/dist/cjs/hooks/useCartLine.js +1 -0
  90. package/dist/cjs/hooks/useCartUI.js +1 -0
  91. package/dist/cjs/hooks/useCollection.js +1 -0
  92. package/dist/cjs/hooks/useFetchHandle.js +1 -0
  93. package/dist/cjs/hooks/useFormatMoney.js +1 -0
  94. package/dist/cjs/hooks/useInitialSwatchesOptions.js +1 -0
  95. package/dist/cjs/hooks/useInteraction.js +1 -0
  96. package/dist/cjs/hooks/useIsomorphicLayoutEffect.js +1 -0
  97. package/dist/cjs/hooks/useLoadScript.js +1 -0
  98. package/dist/cjs/hooks/useMoney.js +1 -0
  99. package/dist/cjs/hooks/usePrevious.js +1 -0
  100. package/dist/cjs/hooks/useProduct.js +18 -0
  101. package/dist/cjs/hooks/useProductList.js +1 -0
  102. package/dist/cjs/hooks/useSuspenseFetch.js +1 -0
  103. package/dist/cjs/hooks/useSwatchesOptions.js +1 -0
  104. package/dist/cjs/hooks/useToolbarPostPurchase.js +1 -0
  105. package/dist/cjs/index.js +18 -0
  106. package/dist/esm/components/AddOn.js +1 -0
  107. package/dist/esm/components/ComponentAnimation.js +1 -0
  108. package/dist/esm/components/ComponentToolbarPreview.js +8 -7
  109. package/dist/esm/components/ComponentWrapper.js +1 -0
  110. package/dist/esm/components/ComponentWrapperPreview.js +3 -2
  111. package/dist/esm/components/Empty.js +1 -0
  112. package/dist/esm/components/InteractionSuffix.js +7 -6
  113. package/dist/esm/components/Render.js +1 -0
  114. package/dist/esm/components/Render.liquid.js +4 -1
  115. package/dist/esm/components/RenderBlock.js +1 -0
  116. package/dist/esm/components/RenderCustomCode.js +8 -7
  117. package/dist/esm/components/RenderPreview.js +1 -0
  118. package/dist/esm/components/RenderSection.js +1 -0
  119. package/dist/esm/components/ai-generator/AIContentGenerator.js +5 -4
  120. package/dist/esm/components/ai-generator/AIGenContentLoading.js +1 -0
  121. package/dist/esm/components/ai-generator/components/PickProduct.js +5 -4
  122. package/dist/esm/components/ai-generator/components/ToneAndVoice.js +1 -0
  123. package/dist/esm/components/ai-generator/icons/AIIcon.js +1 -0
  124. package/dist/esm/components/ai-generator/icons/CloseIcon.js +1 -0
  125. package/dist/esm/components/ai-generator/icons/DropdownIcon.js +1 -0
  126. package/dist/esm/components/ai-generator/icons/SearchIcon.js +1 -0
  127. package/dist/esm/components/ai-generator/icons/ShowMoreIcon.js +1 -0
  128. package/dist/esm/components/ai-generator/icons/UpgradeIcon.js +1 -0
  129. package/dist/esm/components/ai-generator/icons/WarningIcon.js +1 -0
  130. package/dist/esm/components/resize/Resize.js +1 -0
  131. package/dist/esm/components/resize/Spacing.js +8 -7
  132. package/dist/esm/components/theme-section/CreateThemeSection.js +5 -4
  133. package/dist/esm/components/theme-section/ThemeSectionStatus.js +1 -0
  134. package/dist/esm/components/theme-section/ThemeSectionTooltip.js +1 -0
  135. package/dist/esm/components/toolbar/Tooltip.js +1 -0
  136. package/dist/esm/contexts/AddonContext.js +1 -0
  137. package/dist/esm/contexts/ArticleContext.js +1 -0
  138. package/dist/esm/contexts/ArticleListContext.js +1 -0
  139. package/dist/esm/contexts/BuilderComponent.js +1 -0
  140. package/dist/esm/contexts/BuilderContext.js +1 -0
  141. package/dist/esm/contexts/BuilderPreviewContext.js +1 -0
  142. package/dist/esm/contexts/CartLineContext.js +1 -0
  143. package/dist/esm/contexts/CollectionContext.js +1 -0
  144. package/dist/esm/contexts/ModalContext.js +1 -0
  145. package/dist/esm/contexts/PageContext.js +1 -0
  146. package/dist/esm/contexts/ProductContext.js +12 -12
  147. package/dist/esm/contexts/ProductListContext.js +1 -0
  148. package/dist/esm/contexts/SectionContext.js +1 -0
  149. package/dist/esm/contexts/ShopContext.js +1 -0
  150. package/dist/esm/graphql/fragments/preview-theme-page.generated.js +0 -4
  151. package/dist/esm/graphql/fragments/published-theme-page.generated.js +4 -0
  152. package/dist/esm/graphql/queries/articles.generated.js +1 -0
  153. package/dist/esm/graphql/queries/blogs.generated.js +1 -0
  154. package/dist/esm/graphql/queries/shop-shopify.generated.js +9 -0
  155. package/dist/esm/helpers/align.js +18 -1
  156. package/dist/esm/helpers/background.js +6 -2
  157. package/dist/esm/helpers/backgroundImage.js +179 -0
  158. package/dist/esm/helpers/borders.js +17 -1
  159. package/dist/esm/helpers/compose-advance-style.js +71 -1
  160. package/dist/esm/helpers/filter-toolbar-preview.js +1 -0
  161. package/dist/esm/helpers/interaction/index.js +7 -6
  162. package/dist/esm/helpers/is-empty-children.js +1 -0
  163. package/dist/esm/helpers/layout.js +17 -1
  164. package/dist/esm/helpers/radius.js +13 -1
  165. package/dist/esm/helpers/shadow.js +28 -3
  166. package/dist/esm/helpers/size.js +21 -1
  167. package/dist/esm/helpers/third-party/appConfig.js +55 -1
  168. package/dist/esm/helpers/third-party/appSetting.js +187 -6
  169. package/dist/esm/helpers/third-party/constant.js +11 -2
  170. package/dist/esm/helpers/typography.js +10 -2
  171. package/dist/esm/hooks/animation/useAnimationActions.js +1 -0
  172. package/dist/esm/hooks/animation/useAnimationConfig.js +1 -0
  173. package/dist/esm/hooks/animation/useAnimationPreview.js +1 -0
  174. package/dist/esm/hooks/animation/useAnimationTarget.js +1 -0
  175. package/dist/esm/hooks/animation/useApplyAnimation.js +1 -0
  176. package/dist/esm/hooks/articles/useArticlesQuery.js +1 -0
  177. package/dist/esm/hooks/cart/use-add-to-cart.js +1 -0
  178. package/dist/esm/hooks/cart/use-cart-data.js +1 -0
  179. package/dist/esm/hooks/cart/use-cart-discount-codes-update.js +1 -0
  180. package/dist/esm/hooks/cart/use-cart-note-update.js +1 -0
  181. package/dist/esm/hooks/cart/use-create-cart.js +1 -0
  182. package/dist/esm/hooks/cart/use-remove-cart-item.js +1 -0
  183. package/dist/esm/hooks/cart/use-update-cart-item.js +1 -0
  184. package/dist/esm/hooks/shop/use-collection-query.js +1 -0
  185. package/dist/esm/hooks/shop/use-collections-query.js +1 -0
  186. package/dist/esm/hooks/shop/use-product-query.js +1 -0
  187. package/dist/esm/hooks/shop/use-products-query.js +1 -0
  188. package/dist/esm/hooks/shop/useShopifyLink.js +45 -0
  189. package/dist/esm/hooks/shop.js +10 -1
  190. package/dist/esm/hooks/use-current-device.js +2 -1
  191. package/dist/esm/hooks/use-lazy-video.js +1 -0
  192. package/dist/esm/hooks/useAnimations.js +1 -0
  193. package/dist/esm/hooks/useCartId.js +1 -0
  194. package/dist/esm/hooks/useCartLine.js +1 -0
  195. package/dist/esm/hooks/useCartUI.js +1 -0
  196. package/dist/esm/hooks/useCollection.js +1 -0
  197. package/dist/esm/hooks/useFetchHandle.js +1 -0
  198. package/dist/esm/hooks/useFormatMoney.js +1 -0
  199. package/dist/esm/hooks/useInitialSwatchesOptions.js +1 -0
  200. package/dist/esm/hooks/useInteraction.js +1 -0
  201. package/dist/esm/hooks/useIsomorphicLayoutEffect.js +1 -0
  202. package/dist/esm/hooks/useLoadScript.js +1 -0
  203. package/dist/esm/hooks/useMoney.js +1 -0
  204. package/dist/esm/hooks/usePrevious.js +1 -0
  205. package/dist/esm/hooks/useProduct.js +18 -1
  206. package/dist/esm/hooks/useProductList.js +1 -0
  207. package/dist/esm/hooks/useSuspenseFetch.js +1 -0
  208. package/dist/esm/hooks/useSwatchesOptions.js +1 -0
  209. package/dist/esm/hooks/useToolbarPostPurchase.js +1 -0
  210. package/dist/esm/index.js +11 -8
  211. package/dist/types/index.d.ts +728 -253
  212. package/package.json +4 -4
@@ -93,6 +93,13 @@ const overrideSettings = (tag, currentSetting, appSetting)=>{
93
93
  selected_product: appSetting?.['productHandle'] || '{{ product }}'
94
94
  };
95
95
  }
96
+ case 'TrustshopProductReviews':
97
+ {
98
+ return {
99
+ ...currentSetting,
100
+ selected_product: appSetting?.['productHandle'] || '{{ product }}'
101
+ };
102
+ }
96
103
  case 'WhatmoreShoppableVideosreel':
97
104
  {
98
105
  return {
@@ -107,25 +114,32 @@ const overrideSettings = (tag, currentSetting, appSetting)=>{
107
114
  'scroll-video-tile-size-portrait': parseFloat(appSetting?.scrollVideoTitleSizePortrait)
108
115
  };
109
116
  }
110
- case 'KachingBundles':
117
+ case 'PowerfulContactFormBuilder':
111
118
  {
112
119
  return {
113
120
  ...currentSetting,
114
- product: appSetting?.['productHandle'] || '{{ product }}'
121
+ shortcode: appSetting?.shortcode
115
122
  };
116
123
  }
117
- case 'PowerfulContactFormBuilder':
124
+ case 'AftershipEmailMarketingsms':
118
125
  {
119
126
  return {
120
127
  ...currentSetting,
121
- shortcode: appSetting?.shortcode
128
+ embedded_form_id: appSetting?.formId
129
+ };
130
+ }
131
+ case 'SeoantTrustBadgesIcon':
132
+ {
133
+ return {
134
+ ...currentSetting,
135
+ badge_id: appSetting?.BadgeId
122
136
  };
123
137
  }
124
- case 'YotpoReviews':
138
+ case 'PowrContactFormBuilder':
125
139
  {
126
140
  return {
127
141
  ...currentSetting,
128
- product: appSetting?.['productHandle'] || '{{ product }}'
142
+ app_id: appSetting?.appId
129
143
  };
130
144
  }
131
145
  default:
@@ -462,6 +476,70 @@ const GloboProductOptionsVariant = {
462
476
  'app-block': null
463
477
  }
464
478
  };
479
+ const BestBuyFulfillment = {
480
+ BestBuyFulfillment: {
481
+ 'pickup-selector': null
482
+ }
483
+ };
484
+ const AftershipEmailMarketingsms = {
485
+ AftershipEmailMarketingsms: {
486
+ embeded_form: {
487
+ embedded_form_id: ''
488
+ }
489
+ }
490
+ };
491
+ const SegunoEmailMarketing = {
492
+ SegunoEmailMarketing: {
493
+ back_in_stock: {
494
+ heading: '<h3>Get notified when this is back in stock</h3>',
495
+ label_email: 'Email',
496
+ placeholder_email: '',
497
+ show_permission_checkbox: true,
498
+ label_permission: '<p>Also, sign up to receive newsletters</p>',
499
+ label_notify: 'Notify me',
500
+ label_success: '<p>Thanks! You will be notified once the product is back in stock.</p>',
501
+ product_exclusion_tag: 'back-in-stock-excluded',
502
+ default_variant: 'available',
503
+ padding: 0,
504
+ form_gap: 16,
505
+ button_alignment: 'stretch',
506
+ font_size: 16,
507
+ input_font_size: 16,
508
+ button_font_size: 16,
509
+ background_color: '#ffffff',
510
+ text_color: '#121212',
511
+ button_background_color: '#121212',
512
+ button_border_color: '#121212',
513
+ button_text_color: '#ffffff',
514
+ input_background_color: '#ffffff',
515
+ input_border_color: '#121212',
516
+ input_text_color: '#121212',
517
+ custom_css: ''
518
+ },
519
+ newsletter_form: {
520
+ heading: 'Subscribe to our newsletter',
521
+ subheading: '<p>Be the first to know about new collections and exclusive offers.</p>',
522
+ show_first_name: false,
523
+ show_last_name: false,
524
+ show_permission_checkbox: false,
525
+ tags: 'newsletter',
526
+ return_to: '',
527
+ label_first_name: 'First name',
528
+ placeholder_first_name: '',
529
+ label_last_name: 'Last name',
530
+ placeholder_last_name: '',
531
+ label_email: 'Email',
532
+ placeholder_email: '',
533
+ label_permission: '<p>I agree to receive marketing emails</p>',
534
+ label_subscribe: 'Subscribe',
535
+ success_message: 'Thanks for subscribing',
536
+ background_color: '#ffffff',
537
+ text_color: '#1a1b18',
538
+ button_background_color: '#445958',
539
+ button_text_color: '#ffffff'
540
+ }
541
+ }
542
+ };
465
543
  const Trustoo = {
466
544
  Trustoo: {
467
545
  'barrage-carousel': null,
@@ -619,7 +697,110 @@ const LooxReviews = {
619
697
  }
620
698
  }
621
699
  };
700
+ const SeoantTrustBadgesIcon = {
701
+ SeoantTrustBadgesIcon: {
702
+ star_rating: {
703
+ badge_id: null
704
+ }
705
+ }
706
+ };
707
+ const PowrContactFormBuilder = {
708
+ PowrContactFormBuilder: {
709
+ 'app-block': {
710
+ app_id: ''
711
+ }
712
+ }
713
+ };
714
+ const MyappgurusProductReviews = {
715
+ MyappgurusProductReviews: {
716
+ allReviews: {
717
+ Show_by_label: ''
718
+ },
719
+ allReviewsCounter: {
720
+ out_of_label: '',
721
+ stars_based_on_label: '',
722
+ reviews_label: ''
723
+ },
724
+ form: {
725
+ block_heading: '',
726
+ no_rating: '',
727
+ subtitle2: '',
728
+ review_btn: '',
729
+ see_all_reviews_label: '',
730
+ form_heading: '',
731
+ name_label: '',
732
+ email_label: '',
733
+ review_title_label: '',
734
+ review_description_label: '',
735
+ ratings_label: '',
736
+ delivery_ratings_label: '',
737
+ payment_ratings_label: '',
738
+ price_ratings_label: '',
739
+ review_image_label: '',
740
+ submit_btn_label: '',
741
+ cancel_btn_label: '',
742
+ sort_label: '',
743
+ sort1_label: '',
744
+ sort2_label: '',
745
+ sort3_label: '',
746
+ showing_label: '',
747
+ to_label: '',
748
+ of_label: '',
749
+ results_label: ''
750
+ },
751
+ star: null
752
+ }
753
+ };
754
+ const TrustreviewsProductReviews = {
755
+ TrustreviewsProductReviews: {
756
+ questions_widget: {
757
+ product: '{{ product }}'
758
+ },
759
+ 'review-carousel': null,
760
+ reviews_text_widget: null,
761
+ reviews_widget: {
762
+ product: '{{ product }}'
763
+ },
764
+ shop_reviews_widget: null,
765
+ star_rating: {
766
+ product: '{{product}}',
767
+ hide_on_no_reviews: false,
768
+ enable_jsonld: false,
769
+ starsize: 16,
770
+ addtional_text: ''
771
+ },
772
+ 'reviews-testimonials': null,
773
+ all_reviews_widget: null,
774
+ 'review-cards': null,
775
+ 'review-gallery': null,
776
+ medals: null
777
+ }
778
+ };
779
+ const HulkProductOptions = {
780
+ HulkProductOptions: {
781
+ option_block: null
782
+ }
783
+ };
784
+ const TrustshopProductReviews = {
785
+ TrustshopProductReviews: {
786
+ 'widget-product-rating': {
787
+ selected_product: '{{ product }}'
788
+ },
789
+ 'all-reviews': null,
790
+ 'widget-box': null,
791
+ 'review-testimonial': null
792
+ }
793
+ };
622
794
  const composeSettingsByWidgetType = {
795
+ ...TrustshopProductReviews,
796
+ ...HulkProductOptions,
797
+ ...MyappgurusProductReviews,
798
+ ...TrustreviewsProductReviews,
799
+ ...PowrContactFormBuilder,
800
+ ...SeoantTrustBadgesIcon,
801
+ ...SegunoEmailMarketing,
802
+ ...AftershipEmailMarketingsms,
803
+ ...BestBuyFulfillment,
623
804
  ...GloboProductOptionsVariant,
624
805
  ...WishlistKing,
625
806
  ...LoloyalLoyaltyReferrals,
@@ -1,4 +1,4 @@
1
- import { RechargeSubscriptionsConfig, BonLoyaltyRewardsReferralsConfig, SubifySubscriptionsConfig, SelleasyConfig, LoopSubscriptionsConfig, SkioSubscriptionsYcS20Config, ShopifyFormsConfig, ReviewxpoProductReviewsAppConfig, PumperBundlesVolumeDiscountConfig, UnlimitedBundlesDiscountsConfig, KiteFreeGiftDiscountConfig, FastBundleBundlesDiscountsConfig, SimpleBundlesKitsConfig, EasyBundleBuilderSkailamaConfig, PreorderNowPreOrderPqConfig, FlyBundlesUpsellsFbtConfig, JunipProductReviewsUgcConfig, PreorderNowWodPresaleConfig, YotpoReviewsV3UgcConfig, WhatmoreShoppableVideosreelConfig, ProductOptionsCustomizerConfig, AppointmentBookingCowlendarConfig, BoldSubscriptionsConfig, SproutPlantTreesGrowSalesConfig, InstasellShoppableInstagramConfig, GrowaveConfig, LoloyalLoyaltyReferralsConfig, PowerfulContactFormBuilderConfig, WishlistKingConfig, GloboProductOptionsVariantConfig, KachingBundlesConfig, TrustooConfig, LooxReviewsConfig } from './appConfig.js';
1
+ import { RechargeSubscriptionsConfig, BonLoyaltyRewardsReferralsConfig, SubifySubscriptionsConfig, SelleasyConfig, LoopSubscriptionsConfig, SkioSubscriptionsYcS20Config, ShopifyFormsConfig, ReviewxpoProductReviewsAppConfig, PumperBundlesVolumeDiscountConfig, UnlimitedBundlesDiscountsConfig, KiteFreeGiftDiscountConfig, FastBundleBundlesDiscountsConfig, SimpleBundlesKitsConfig, EasyBundleBuilderSkailamaConfig, PreorderNowPreOrderPqConfig, FlyBundlesUpsellsFbtConfig, JunipProductReviewsUgcConfig, PreorderNowWodPresaleConfig, YotpoReviewsV3UgcConfig, WhatmoreShoppableVideosreelConfig, ProductOptionsCustomizerConfig, AppointmentBookingCowlendarConfig, BoldSubscriptionsConfig, SproutPlantTreesGrowSalesConfig, InstasellShoppableInstagramConfig, GrowaveConfig, LoloyalLoyaltyReferralsConfig, PowerfulContactFormBuilderConfig, WishlistKingConfig, GloboProductOptionsVariantConfig, KachingBundlesConfig, BestBuyFulfillmentConfig, AftershipEmailMarketingsmsConfig, SegunoEmailMarketingConfig, TrustooConfig, LooxReviewsConfig, SeoantTrustBadgesIconConfig, PowrContactFormBuilderConfig, MyappgurusProductReviewsConfig, TrustreviewsProductReviewsConfig, HulkProductOptionsConfig, TrustshopProductReviewsConfig } from './appConfig.js';
2
2
 
3
3
  const mapShopifyAppMeta = {
4
4
  ...RechargeSubscriptionsConfig,
@@ -32,8 +32,17 @@ const mapShopifyAppMeta = {
32
32
  ...WishlistKingConfig,
33
33
  ...GloboProductOptionsVariantConfig,
34
34
  ...KachingBundlesConfig,
35
+ ...BestBuyFulfillmentConfig,
36
+ ...AftershipEmailMarketingsmsConfig,
37
+ ...SegunoEmailMarketingConfig,
35
38
  ...TrustooConfig,
36
- ...LooxReviewsConfig
39
+ ...LooxReviewsConfig,
40
+ ...SeoantTrustBadgesIconConfig,
41
+ ...PowrContactFormBuilderConfig,
42
+ ...MyappgurusProductReviewsConfig,
43
+ ...TrustreviewsProductReviewsConfig,
44
+ ...HulkProductOptionsConfig,
45
+ ...TrustshopProductReviewsConfig
37
46
  };
38
47
  const THIRD_PARTY_APP_BLOCK_ID_PREFIX = 'gp_app';
39
48
 
@@ -22,7 +22,7 @@ const composeTypographyV2Css = (typography, isImportant)=>{
22
22
  const typographyCustom = typography?.custom;
23
23
  const { fontFamily, fontSize, fontWeight, lineHeight, letterSpacing } = typographyCustom ?? {};
24
24
  const typographyAttrs = typography?.attrs;
25
- const { bold, italic, underline, transform } = typographyAttrs ?? {};
25
+ const { bold, italic, underline, transform, color } = typographyAttrs ?? {};
26
26
  const composeImportant = isImportant ? '!important' : '';
27
27
  return `
28
28
  ${fontFamily ? `font-family: ${composeFontFamilyTypographyV2({
@@ -30,6 +30,7 @@ const composeTypographyV2Css = (typography, isImportant)=>{
30
30
  type: typography?.type
31
31
  })} ${composeImportant}` : ''};
32
32
  ${fontSize?.desktop ? `font-size: ${fontSize?.desktop} ${composeImportant}` : ''};
33
+ ${color ? `color: ${color} ${composeImportant}` : ''};
33
34
  ${bold ? `font-weight: bold ${composeImportant}` : fontWeight ? `font-weight: ${fontWeight} ${composeImportant}` : ''};
34
35
  ${letterSpacing ? `letter-spacing: ${letterSpacing} ${composeImportant}` : ''};
35
36
  ${lineHeight?.desktop ? `line-height: ${lineHeight?.desktop} ${composeImportant}` : ''};
@@ -38,6 +39,13 @@ const composeTypographyV2Css = (typography, isImportant)=>{
38
39
  ${transform ? `text-transform: ${transform} ${composeImportant}` : ''};
39
40
  `;
40
41
  };
42
+ const composeTextHoverColorCss = (device, colorHoverConfig, isImportant)=>{
43
+ if (colorHoverConfig) {
44
+ const composeImportant = isImportant ? '!important' : '';
45
+ const color = colorHoverConfig[device]?.hover;
46
+ return `${color ? `color: ${color} ${composeImportant}` : ''}`;
47
+ }
48
+ };
41
49
  function getCustomCSSByDevice(typography, device) {
42
50
  if (!typography || !device) return {};
43
51
  const suffix = device === 'desktop' || !device ? '' : `-${device}`;
@@ -146,4 +154,4 @@ const isCustomTypo = (customTypo)=>{
146
154
  return customTypo && Object.keys(customTypo).length > 1 || customTypo && Object.keys(customTypo).length === 1 && !customTypo.fontSize;
147
155
  };
148
156
 
149
- export { composeFallbackTypographyStyle, composeFontFamilyTypographyV2, composeTypography, composeTypographyAttr, composeTypographyClassName, composeTypographyCss, composeTypographyStyle, composeTypographyV2, composeTypographyV2Css, genTypoClass };
157
+ export { composeFallbackTypographyStyle, composeFontFamilyTypographyV2, composeTextHoverColorCss, composeTypography, composeTypographyAttr, composeTypographyClassName, composeTypographyCss, composeTypographyStyle, composeTypographyV2, composeTypographyV2Css, genTypoClass };
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useRef, useCallback } from 'react';
2
3
 
3
4
  const useAnimationActions = ()=>{
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useMemo, useCallback } from 'react';
2
3
  import { useCurrentDevice } from '../use-current-device.js';
3
4
 
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useCallback } from 'react';
2
3
 
3
4
  const useAnimationPreview = ({ props, playAnimation, cancelAnimation, setAnimationOnFinish, setToolbarActive })=>{
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useRef, useCallback } from 'react';
2
3
  import { useAnimationConfig } from './useAnimationConfig.js';
3
4
 
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useCallback, useEffect } from 'react';
2
3
  import { useAnimations } from '../useAnimations.js';
3
4
  import { useAnimationTarget } from './useAnimationTarget.js';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { ArticlesDocument } from '../../graphql/queries/articles.generated.js';
2
3
  import { useFetchHandle } from '../useFetchHandle.js';
3
4
  import useSWR from 'swr';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { addToCartOperation } from '@gem-sdk/adapter-shopify';
2
3
  import { useSWRConfig } from 'swr';
3
4
  import useSWRMutation from 'swr/mutation';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { getCartOperation } from '@gem-sdk/adapter-shopify';
2
3
  import useSWR from 'swr';
3
4
  import { useStoreFront } from '../shop.js';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { cartDiscountCodesUpdateOperation } from '@gem-sdk/adapter-shopify';
2
3
  import { useSWRConfig } from 'swr';
3
4
  import useSWRMutation from 'swr/mutation';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { cartNoteUpdateOperation } from '@gem-sdk/adapter-shopify';
2
3
  import { useSWRConfig } from 'swr';
3
4
  import useSWRMutation from 'swr/mutation';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { createCartOperation } from '@gem-sdk/adapter-shopify';
2
3
  import { useSWRConfig } from 'swr';
3
4
  import useSWRMutation from 'swr/mutation';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { removeCartItemOperation } from '@gem-sdk/adapter-shopify';
2
3
  import { useSWRConfig } from 'swr';
3
4
  import useSWRMutation from 'swr/mutation';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { updateCartLineOperation } from '@gem-sdk/adapter-shopify';
2
3
  import { useSWRConfig } from 'swr';
3
4
  import useSWRMutation from 'swr/mutation';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import useSWR from 'swr';
2
3
  import { getCollection } from '../../helpers/queries/get-collection.js';
3
4
  import { useIsSampleProduct, useIsStorefrontProduct } from '../shop.js';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import useSWR from 'swr';
2
3
  import { getCollections } from '../../helpers/queries/get-collections.js';
3
4
  import { useFetchHandle } from '../useFetchHandle.js';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import useSWR from 'swr';
2
3
  import { getProduct } from '../../helpers/queries/get-product.js';
3
4
  import { useIsSampleProduct, useIsStorefrontProduct } from '../shop.js';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import useSWR from 'swr';
2
3
  import useSWRInfinite from 'swr/infinite';
3
4
  import { getProducts, getProductQueryAll, getListProductByVariables } from '../../helpers/queries/get-products.js';
@@ -0,0 +1,45 @@
1
+ 'use client';
2
+ import { useMemo } from 'react';
3
+ import { useShopStore } from '../../contexts/ShopContext.js';
4
+
5
+ const useShopifyLink = ({ productId, articleId })=>{
6
+ const storefrontUrl = useShopStore((s)=>s.storefrontUrl);
7
+ //
8
+ // const productId = useMemo(() => {
9
+ // const ele = document.querySelector(`[data-uid="${parentProductUid}"]`);
10
+ // return ele?.getAttribute('data-product-id');
11
+ // }, [parentProductUid]);
12
+ const shopName = useMemo(()=>{
13
+ const pattern = /^(?:https?:\/\/)?([^/]+)\.myshopify\.com/;
14
+ if (storefrontUrl) {
15
+ return storefrontUrl.match(pattern)?.[1];
16
+ }
17
+ return '';
18
+ }, [
19
+ storefrontUrl
20
+ ]);
21
+ const linkShopDefault = useMemo(()=>{
22
+ return `https://admin.shopify.com/store/${shopName}`;
23
+ }, [
24
+ shopName
25
+ ]);
26
+ const linkEditProduct = useMemo(()=>{
27
+ return productId ? `${linkShopDefault}/products/${productId}` : '';
28
+ }, [
29
+ linkShopDefault,
30
+ productId
31
+ ]);
32
+ const linkEditArticle = useMemo(()=>{
33
+ return articleId ? `${linkShopDefault}/articles/${articleId}` : '';
34
+ }, [
35
+ articleId,
36
+ linkShopDefault
37
+ ]);
38
+ return {
39
+ linkShopDefault,
40
+ linkEditProduct,
41
+ linkEditArticle
42
+ };
43
+ };
44
+
45
+ export { useShopifyLink };
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useMemo } from 'react';
2
3
  import { useSWRConfig } from 'swr';
3
4
  import { useShopStore } from '../contexts/ShopContext.js';
@@ -24,6 +25,14 @@ const useCurrency = ()=>{
24
25
  changeCurrency
25
26
  ]);
26
27
  };
28
+ const useTimezone = ()=>{
29
+ const timezone = useShopStore((state)=>state.timezone);
30
+ return useMemo(()=>({
31
+ timezone
32
+ }), [
33
+ timezone
34
+ ]);
35
+ };
27
36
  const useMoneyFormat = ()=>{
28
37
  const moneyFormat = useShopStore((state)=>state.moneyFormat);
29
38
  const moneyWithCurrencyFormat = useShopStore((state)=>state.moneyWithCurrencyFormat);
@@ -108,4 +117,4 @@ function useCheckoutUrl(url) {
108
117
  return storefrontToken ? `${url}?access_token=${storefrontToken}` : url;
109
118
  }
110
119
 
111
- export { useCheckoutUrl, useConnectedShopify, useCurrency, useEditorMode, useIsSampleProduct, useIsStorefrontProduct, useLocale, useMatchMutate, useMobileOnly, useMoneyFormat, usePageType, usePluginEnable, useStoreFront, useSwatches };
120
+ export { useCheckoutUrl, useConnectedShopify, useCurrency, useEditorMode, useIsSampleProduct, useIsStorefrontProduct, useLocale, useMatchMutate, useMobileOnly, useMoneyFormat, usePageType, usePluginEnable, useStoreFront, useSwatches, useTimezone };
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useSyncExternalStore } from 'react';
2
3
 
3
4
  // Hàm debounce với TypeScript
@@ -17,7 +18,7 @@ const useCurrentDevice = ()=>{
17
18
  return useSyncExternalStore(subscribe, ()=>{
18
19
  if (window.innerWidth < 768) {
19
20
  return 'mobile';
20
- } else if (window.innerWidth >= 768 && window.innerWidth < 1024) {
21
+ } else if (window.innerWidth >= 768 && window.innerWidth < 1025) {
21
22
  return 'tablet';
22
23
  } else {
23
24
  return 'desktop';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useEffect } from 'react';
2
3
  import LazyLoad from 'vanilla-lazyload';
3
4
 
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { animations } from '../helpers/animations.js';
2
3
  import 'react';
3
4
  import 'react/jsx-runtime';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useSyncExternalStore, useCallback, useMemo } from 'react';
2
3
 
3
4
  const cartKey = 'cart-id';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useCartLineStore } from '../contexts/CartLineContext.js';
2
3
 
3
4
  const useCartLine = ()=>{
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useCallback } from 'react';
2
3
  import { create } from 'zustand';
3
4
  import { usePluginEnable } from './shop.js';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useCollectionStore } from '../contexts/CollectionContext.js';
2
3
 
3
4
  const useCollection = ()=>{
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useSWRConfig } from 'swr';
2
3
 
3
4
  const useFetchHandle = ()=>{
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useMoneyFormat } from './shop.js';
2
3
 
3
4
  const shopifyPriceRounding = (amount, precision)=>{
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import useSWR from 'swr';
2
3
  import { ProductOptionNameDocument } from '../graphql/queries/product-value-label.generated.js';
3
4
  import { colorPreset } from '../components/src/product/helpers/variant-presets.js';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { usePageStore } from '../contexts/PageContext.js';
2
3
 
3
4
  const useInteraction = ()=>{
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useLayoutEffect } from 'react';
2
3
 
3
4
  // const isBrowser = typeof window !== 'undefined';
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useState, useEffect } from 'react';
2
3
  import { loadScript } from '../helpers/load-script.js';
3
4
 
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useMemo } from 'react';
2
3
  import { useLocale, useCurrency } from './shop.js';
3
4
 
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useRef, useEffect } from 'react';
2
3
 
3
4
  const usePrevious = (value)=>{
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useCallback, useEffect, useMemo } from 'react';
2
3
  import { useProductStore } from '../contexts/ProductContext.js';
3
4
  import 'react/jsx-runtime';
@@ -10,6 +11,7 @@ import 'swr/infinite';
10
11
  import 'vanilla-lazyload';
11
12
  import './useCartUI.js';
12
13
  import { checkInStock } from '../helpers/variant.js';
14
+ import { useShopifyLink } from './shop/useShopifyLink.js';
13
15
  import 'react-transition-group';
14
16
  import '@gem-sdk/core';
15
17
  import 'classnames';
@@ -41,6 +43,21 @@ const useProductBundleDiscount = ()=>{
41
43
  seUseProductCompareAtPrice
42
44
  };
43
45
  };
46
+ const useProductShopifyEditLink = ()=>{
47
+ const product = useProductStore((s)=>s.product);
48
+ const productId = product?.baseID?.replace('gid://shopify/Product/', '');
49
+ const { linkEditProduct } = useShopifyLink({
50
+ productId
51
+ });
52
+ const redirectProductShopifyLink = ()=>{
53
+ if (!linkEditProduct) return;
54
+ window.open(linkEditProduct, '_blank');
55
+ };
56
+ return {
57
+ linkEditProduct,
58
+ redirectProductShopifyLink
59
+ };
60
+ };
44
61
  const useQuantity = ()=>{
45
62
  const quantity = useProductStore((s)=>s.quantity);
46
63
  const hasUpdatePrice = useProductStore((s)=>s.updatePrice);
@@ -225,4 +242,4 @@ const useProductOfferDiscount = ()=>{
225
242
  return currentDiscount || 0;
226
243
  };
227
244
 
228
- export { useCheckAvailableVariantInStock, useCurrentVariant, useCurrentVariantInStock, useFeaturedImageGlobal, useHasPreSelected, useIsSyncProduct, useProduct, useProductBundleDiscount, useProductOfferDiscount, useProductProperties, useQuantity, useSelectedOption, useUniqProductID, useVariant, useVariantOutStock, useVariants };
245
+ export { useCheckAvailableVariantInStock, useCurrentVariant, useCurrentVariantInStock, useFeaturedImageGlobal, useHasPreSelected, useIsSyncProduct, useProduct, useProductBundleDiscount, useProductOfferDiscount, useProductProperties, useProductShopifyEditLink, useQuantity, useSelectedOption, useUniqProductID, useVariant, useVariantOutStock, useVariants };
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useProductListStore } from '../contexts/ProductListContext.js';
2
3
 
3
4
  const useProductList = ()=>{
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  const cache = new Map();
2
3
  const useSuspenseFetch = (key, promise)=>{
3
4
  const value = cache.get(key) || {
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { useSwatches } from './shop.js';
2
3
 
3
4
  const initialSwatchOptionValue = {
@@ -1,3 +1,4 @@
1
+ 'use client';
1
2
  import { postPurchaseRequiredElements, postPurchaseWrapElements } from '../components/constant.js';
2
3
  import { useShopStore } from '../contexts/ShopContext.js';
3
4