@gem-sdk/components 2.0.0-dev.267 → 2.0.0-dev.271

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 (58) hide show
  1. package/dist/cjs/breadcrumb/components/common/style.js +2 -2
  2. package/dist/cjs/builder.js +14 -14
  3. package/dist/cjs/collection/setting/collection-banner/configs/uiV2.js +1 -1
  4. package/dist/cjs/grid/col/Col.liquid.js +2 -2
  5. package/dist/cjs/grid/row/Row.js +2 -2
  6. package/dist/cjs/grid/row/Row.liquid.js +1 -2
  7. package/dist/cjs/grid/row/commons/getStyle.js +6 -6
  8. package/dist/cjs/grid/row/setting/configs/uiV2.js +1 -1
  9. package/dist/cjs/grid/section/setting/configs/uiV2.js +1 -1
  10. package/dist/cjs/index.js +84 -84
  11. package/dist/cjs/index.liquid.js +8 -8
  12. package/dist/cjs/post-purchase/callout-banner/components/common/getStyles.js +2 -0
  13. package/dist/cjs/post-purchase/callout-banner/setting/config/callout-box/setting.js +10 -10
  14. package/dist/cjs/post-purchase/callout-banner/setting/config/callout-text/setting.js +1 -5
  15. package/dist/cjs/post-purchase/product/components/ProductPriceBreakdown.js +14 -5
  16. package/dist/cjs/post-purchase/product/components/priceBreakdown/MoneyLine.js +9 -4
  17. package/dist/cjs/post-purchase/product/helpers/product-price-breakdown/getClasses.js +29 -1
  18. package/dist/cjs/post-purchase/product/settings/product-price/uiV2.js +3 -0
  19. package/dist/cjs/post-purchase/product/settings/product-price-breakdown/configs/uiV2.js +3 -3
  20. package/dist/cjs/post-purchase/utils/constants.js +1 -1
  21. package/dist/cjs/product/components/ProductQuickView/ProductQuickView.js +4 -4
  22. package/dist/cjs/product/components/ProductTitle/common/gpCommon.js +17 -0
  23. package/dist/cjs/product/components/ProductTitle/index.js +49 -0
  24. package/dist/cjs/product/components/ProductTitle/index.liquid.js +30 -0
  25. package/dist/cjs/product/next.js +1 -1
  26. package/dist/cjs/product/setting/product/configs/uiV2.js +1 -1
  27. package/dist/esm/breadcrumb/components/common/style.js +2 -2
  28. package/dist/esm/builder.js +1 -1
  29. package/dist/esm/collection/setting/collection-banner/configs/uiV2.js +1 -1
  30. package/dist/esm/grid/col/Col.liquid.js +2 -2
  31. package/dist/esm/grid/row/Row.js +2 -2
  32. package/dist/esm/grid/row/Row.liquid.js +1 -2
  33. package/dist/esm/grid/row/commons/getStyle.js +7 -7
  34. package/dist/esm/grid/row/setting/configs/uiV2.js +1 -1
  35. package/dist/esm/grid/section/setting/configs/uiV2.js +1 -1
  36. package/dist/esm/index.js +1 -1
  37. package/dist/esm/index.liquid.js +1 -1
  38. package/dist/esm/post-purchase/callout-banner/components/common/getStyles.js +2 -0
  39. package/dist/esm/post-purchase/callout-banner/setting/config/callout-box/setting.js +10 -10
  40. package/dist/esm/post-purchase/callout-banner/setting/config/callout-text/setting.js +1 -5
  41. package/dist/esm/post-purchase/product/components/ProductPriceBreakdown.js +14 -5
  42. package/dist/esm/post-purchase/product/components/priceBreakdown/MoneyLine.js +9 -4
  43. package/dist/esm/post-purchase/product/helpers/product-price-breakdown/getClasses.js +27 -2
  44. package/dist/esm/post-purchase/product/settings/product-price/uiV2.js +3 -0
  45. package/dist/esm/post-purchase/product/settings/product-price-breakdown/configs/uiV2.js +3 -3
  46. package/dist/esm/post-purchase/utils/constants.js +1 -1
  47. package/dist/esm/product/components/ProductQuickView/ProductQuickView.js +1 -1
  48. package/dist/esm/product/components/ProductTitle/common/gpCommon.js +15 -0
  49. package/dist/esm/product/components/ProductTitle/index.js +45 -0
  50. package/dist/esm/product/components/ProductTitle/index.liquid.js +26 -0
  51. package/dist/esm/product/next.js +1 -1
  52. package/dist/esm/product/setting/product/configs/uiV2.js +1 -1
  53. package/dist/types/index.d.ts +8 -3
  54. package/package.json +1 -1
  55. package/dist/cjs/product/components/ProductTitle.js +0 -43
  56. package/dist/cjs/product/components/ProductTitle.liquid.js +0 -44
  57. package/dist/esm/product/components/ProductTitle.js +0 -39
  58. package/dist/esm/product/components/ProductTitle.liquid.js +0 -40
@@ -1,39 +0,0 @@
1
- 'use client';
2
- import { jsx } from 'react/jsx-runtime';
3
- import Link from 'next/link';
4
- import { useProduct } from '@gem-sdk/core';
5
- import Text from '../../text/components/Text.js';
6
- import { urlJoin } from '../../link/helpers/url-join.js';
7
-
8
- const ProductTitle = ({ setting, builderProps, styles })=>{
9
- const product = useProduct();
10
- const destination = product?.handle ? urlJoin('/products', product.handle) : '#';
11
- const currentProductId = product?.baseID?.replace('gid://shopify/Product/', '');
12
- return /*#__PURE__*/ jsx("div", {
13
- id: `shopify-text-element-${builderProps?.uid}`,
14
- "data-product-id": currentProductId,
15
- children: !product ? null : setting?.linkProduct ? /*#__PURE__*/ jsx(Link, {
16
- href: destination,
17
- title: product?.title,
18
- children: /*#__PURE__*/ jsx(Text, {
19
- builderProps: builderProps,
20
- styles: styles,
21
- setting: {
22
- ...setting,
23
- text: product.title,
24
- excludeFlex: true
25
- }
26
- })
27
- }) : /*#__PURE__*/ jsx(Text, {
28
- builderProps: builderProps,
29
- styles: styles,
30
- setting: {
31
- ...setting,
32
- text: product.title,
33
- excludeFlex: true
34
- }
35
- })
36
- });
37
- };
38
-
39
- export { ProductTitle as default };
@@ -1,40 +0,0 @@
1
- import { template } from '@gem-sdk/core';
2
- import Text from '../../text/components/Text.liquid.js';
3
- import { getStaticLocale } from '../../helpers.js';
4
-
5
- const ProductTitle = ({ setting, styles, advanced, builderProps })=>{
6
- return template`
7
- {%- unless product -%}
8
- <p>${getStaticLocale('ProductTitle', 'product_not_found')}</p>
9
- {%- else -%}
10
- ${setting?.linkProduct ? `
11
- <a href="{{ product.url }}" title="{{ product.title }}" class="gp-product-title-link-wrapper">
12
- ${Text({
13
- styles: styles,
14
- setting: {
15
- ...setting,
16
- text: '{{ product.title }}',
17
- excludeFlex: true
18
- },
19
- advanced: advanced,
20
- builderProps
21
- })}
22
- </a>
23
- ` : `
24
- ${Text({
25
- styles: styles,
26
- setting: {
27
- ...setting,
28
- text: '{{ product.title }}',
29
- excludeFlex: true
30
- },
31
- advanced: advanced,
32
- className: 'gp-product-title',
33
- builderProps
34
- })}
35
- `}
36
- {%- endunless -%}
37
- `;
38
- };
39
-
40
- export { ProductTitle as default };