@gem-sdk/components 2.0.0-staging.126 → 2.0.0-staging.127

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.
@@ -36,6 +36,7 @@ const Column = ({ children, className, style, builderAttrs, builderProps, advanc
36
36
  ...core.makeStyleResponsive('o', orderRender)
37
37
  },
38
38
  className: core.cls(className, builderProps?.uid, 'gp-relative gp-flex gp-flex-col', styles?.fullWidth ? 'gp-w-full' : ''),
39
+ "data-same-height-display-contents": !!setting?.allowSameHeight,
39
40
  children: core.isEmptyChildren(children) ? /*#__PURE__*/ jsxRuntime.jsx(ChildrenDroppable.default, {}) : children
40
41
  });
41
42
  };
@@ -32,6 +32,7 @@ const Column = ({ children, className, style, builderAttrs, builderProps, advanc
32
32
  ...core.makeStyleResponsive('d', children ? styles?.display : displayByBreakpointIfChildrenEmpty)
33
33
  }}"
34
34
  class="${core.cls(className, builderProps?.uid, advanced?.cssClass, 'gp-relative gp-flex gp-flex-col', styles?.fullWidth ? 'gp-w-full' : '')}"
35
+ data-same-height-display-contents="${!!setting?.allowSameHeight}"
35
36
  >
36
37
  ${children ?? ''}
37
38
  </div>`;
@@ -161,6 +161,7 @@ const Row = ({ className, children, setting, builderAttrs, builderProps, styles,
161
161
  }),
162
162
  /*#__PURE__*/ jsxRuntime.jsx(Element, {
163
163
  className: "gp-max-w-full [&_*]:gp-max-w-full",
164
+ "data-same-height-display-contents": !!setting?.allowSameHeight,
164
165
  style: {
165
166
  ...wrapStyle,
166
167
  ...core.makeStyleResponsive('pl', styleObject.padding),
@@ -61,6 +61,7 @@ const Row = ({ className, children, setting, builderAttrs, builderProps, styles,
61
61
  ${core.template`
62
62
  <${elementTag}
63
63
  class="gp-max-w-full ${isSection ? helpers.getSettingPreloadData('gps-lazy') : ''}"
64
+ data-same-height-display-contents="${!!setting?.allowSameHeight}"
64
65
  style="${{
65
66
  ...wrapStyle,
66
67
  ...core.makeStyleResponsive('pl', styleObject.padding),
@@ -334,7 +334,7 @@ const ProductList = ({ children, className, setting, styles, builderProps })=>{
334
334
  'data-component-no-setting': true,
335
335
  'data-product-id': product?.baseID?.replace('gid://shopify/Product/', '')
336
336
  } : {},
337
- className: core.cls(setting?.sameHeight ? `gp-contents [&>div]:gp-grid [&>div]:gp-grid-rows-[subgrid] [&>div]:gp-gap-y-0 [&>div]:gp-grid-col-[subgrid] ${mode === 'edit' ? '[&>*>div[data-component-tag="Col"]]:gp-contents' : '[&>*>div]:gp-contents'}` : '', `gp-child-item-${builderProps?.uid}`),
337
+ className: core.cls(setting?.sameHeight ? `gp-contents [&_*[data-same-height-display-contents="true"]]:gp-contents [&_*[data-component-label="Row"]]:gp-grid [&_*[data-component-label="Row"]]:gp-grid-rows-[subgrid] [&_*[data-component-label="Row"]]:gp-gap-y-0 [&_*[data-component-label="Row"]]:gp-grid-col-[subgrid]` : '', `gp-child-item-${builderProps?.uid}`),
338
338
  style: {
339
339
  '--grchild': setting?.sameHeight ? generateGridRowArray[index]?.gridRow : undefined,
340
340
  '--mbchild': generateGridRowArray[index]?.marginBottom
@@ -141,7 +141,7 @@ const ProductList = ({ setting, builderProps, styles, className, children, advan
141
141
  gp-context='{"variantSelected": {{ variant | json | escape }}, "quantity": 1 , "formId": "{{ product_form_id }}"}'
142
142
  gp-data='{"variantSelected": {{ variant | json | escape }}, "quantity": 1, "productUrl":{{ product.url | json | escape }}, "productHandle":{{ product.handle | json | escape }}, "collectionUrl": {{ collection.url | json | escape }}, "collectionHandle": {{ collection.handle | json | escape }},"pageContext" : ${JSON.stringify(pageContext)}}'
143
143
  >
144
- {%- form 'product', product, id: product_form_id, class: 'form contents ${setting?.sameHeight ? ' gp-contents [&>div]:gp-grid [&>div]:gp-grid-rows-[subgrid] [&>div]:gp-gap-y-0 [&>div]:gp-grid-col-[subgrid] [&>*>div:nth-child(1)]:gp-contents' : ''}', data-type: 'add-to-cart-form', autocomplete: 'off' -%}
144
+ {%- form 'product', product, id: product_form_id, class: 'form contents ${setting?.sameHeight ? ' gp-contents [&_*[data-same-height-display-contents="true"]]:gp-contents [&_*[parenttag="ProductList"]]:gp-grid [&_*[parenttag="ProductList"]]:gp-grid-rows-[subgrid] [&_*[parenttag="ProductList"]]:gp-gap-y-0 [&_*[parenttag="ProductList"]]:gp-grid-col-[subgrid]' : ''}', data-type: 'add-to-cart-form', autocomplete: 'off' -%}
145
145
  <input type="hidden" name="id" value="{{ variant.id }}" />
146
146
  <input type="hidden" min="1" name="quantity" value="{{ quantity }}" />
147
147
  <button type="submit" onclick="return false;" style="display:none;"></button>
@@ -932,7 +932,8 @@ const config = {
932
932
  ],
933
933
  display: 'fill'
934
934
  }
935
- }
935
+ },
936
+ allowSameHeight: true
936
937
  },
937
938
  styles: {
938
939
  verticalGutter: {
@@ -977,7 +978,8 @@ const config = {
977
978
  tag: 'Col',
978
979
  label: 'Block',
979
980
  settings: {
980
- fullHeight: true
981
+ fullHeight: true,
982
+ allowSameHeight: true
981
983
  },
982
984
  styles: {
983
985
  justifyContent: {
@@ -32,6 +32,7 @@ const Column = ({ children, className, style, builderAttrs, builderProps, advanc
32
32
  ...makeStyleResponsive('o', orderRender)
33
33
  },
34
34
  className: cls(className, builderProps?.uid, 'gp-relative gp-flex gp-flex-col', styles?.fullWidth ? 'gp-w-full' : ''),
35
+ "data-same-height-display-contents": !!setting?.allowSameHeight,
35
36
  children: isEmptyChildren(children) ? /*#__PURE__*/ jsx(ChildrenDroppable, {}) : children
36
37
  });
37
38
  };
@@ -28,6 +28,7 @@ const Column = ({ children, className, style, builderAttrs, builderProps, advanc
28
28
  ...makeStyleResponsive('d', children ? styles?.display : displayByBreakpointIfChildrenEmpty)
29
29
  }}"
30
30
  class="${cls(className, builderProps?.uid, advanced?.cssClass, 'gp-relative gp-flex gp-flex-col', styles?.fullWidth ? 'gp-w-full' : '')}"
31
+ data-same-height-display-contents="${!!setting?.allowSameHeight}"
31
32
  >
32
33
  ${children ?? ''}
33
34
  </div>`;
@@ -157,6 +157,7 @@ const Row = ({ className, children, setting, builderAttrs, builderProps, styles,
157
157
  }),
158
158
  /*#__PURE__*/ jsx(Element, {
159
159
  className: "gp-max-w-full [&_*]:gp-max-w-full",
160
+ "data-same-height-display-contents": !!setting?.allowSameHeight,
160
161
  style: {
161
162
  ...wrapStyle,
162
163
  ...makeStyleResponsive('pl', styleObject.padding),
@@ -57,6 +57,7 @@ const Row = ({ className, children, setting, builderAttrs, builderProps, styles,
57
57
  ${template`
58
58
  <${elementTag}
59
59
  class="gp-max-w-full ${isSection ? getSettingPreloadData('gps-lazy') : ''}"
60
+ data-same-height-display-contents="${!!setting?.allowSameHeight}"
60
61
  style="${{
61
62
  ...wrapStyle,
62
63
  ...makeStyleResponsive('pl', styleObject.padding),
@@ -330,7 +330,7 @@ const ProductList = ({ children, className, setting, styles, builderProps })=>{
330
330
  'data-component-no-setting': true,
331
331
  'data-product-id': product?.baseID?.replace('gid://shopify/Product/', '')
332
332
  } : {},
333
- className: cls(setting?.sameHeight ? `gp-contents [&>div]:gp-grid [&>div]:gp-grid-rows-[subgrid] [&>div]:gp-gap-y-0 [&>div]:gp-grid-col-[subgrid] ${mode === 'edit' ? '[&>*>div[data-component-tag="Col"]]:gp-contents' : '[&>*>div]:gp-contents'}` : '', `gp-child-item-${builderProps?.uid}`),
333
+ className: cls(setting?.sameHeight ? `gp-contents [&_*[data-same-height-display-contents="true"]]:gp-contents [&_*[data-component-label="Row"]]:gp-grid [&_*[data-component-label="Row"]]:gp-grid-rows-[subgrid] [&_*[data-component-label="Row"]]:gp-gap-y-0 [&_*[data-component-label="Row"]]:gp-grid-col-[subgrid]` : '', `gp-child-item-${builderProps?.uid}`),
334
334
  style: {
335
335
  '--grchild': setting?.sameHeight ? generateGridRowArray[index]?.gridRow : undefined,
336
336
  '--mbchild': generateGridRowArray[index]?.marginBottom
@@ -137,7 +137,7 @@ const ProductList = ({ setting, builderProps, styles, className, children, advan
137
137
  gp-context='{"variantSelected": {{ variant | json | escape }}, "quantity": 1 , "formId": "{{ product_form_id }}"}'
138
138
  gp-data='{"variantSelected": {{ variant | json | escape }}, "quantity": 1, "productUrl":{{ product.url | json | escape }}, "productHandle":{{ product.handle | json | escape }}, "collectionUrl": {{ collection.url | json | escape }}, "collectionHandle": {{ collection.handle | json | escape }},"pageContext" : ${JSON.stringify(pageContext)}}'
139
139
  >
140
- {%- form 'product', product, id: product_form_id, class: 'form contents ${setting?.sameHeight ? ' gp-contents [&>div]:gp-grid [&>div]:gp-grid-rows-[subgrid] [&>div]:gp-gap-y-0 [&>div]:gp-grid-col-[subgrid] [&>*>div:nth-child(1)]:gp-contents' : ''}', data-type: 'add-to-cart-form', autocomplete: 'off' -%}
140
+ {%- form 'product', product, id: product_form_id, class: 'form contents ${setting?.sameHeight ? ' gp-contents [&_*[data-same-height-display-contents="true"]]:gp-contents [&_*[parenttag="ProductList"]]:gp-grid [&_*[parenttag="ProductList"]]:gp-grid-rows-[subgrid] [&_*[parenttag="ProductList"]]:gp-gap-y-0 [&_*[parenttag="ProductList"]]:gp-grid-col-[subgrid]' : ''}', data-type: 'add-to-cart-form', autocomplete: 'off' -%}
141
141
  <input type="hidden" name="id" value="{{ variant.id }}" />
142
142
  <input type="hidden" min="1" name="quantity" value="{{ quantity }}" />
143
143
  <button type="submit" onclick="return false;" style="display:none;"></button>
@@ -928,7 +928,8 @@ const config = {
928
928
  ],
929
929
  display: 'fill'
930
930
  }
931
- }
931
+ },
932
+ allowSameHeight: true
932
933
  },
933
934
  styles: {
934
935
  verticalGutter: {
@@ -973,7 +974,8 @@ const config = {
973
974
  tag: 'Col',
974
975
  label: 'Block',
975
976
  settings: {
976
- fullHeight: true
977
+ fullHeight: true,
978
+ allowSameHeight: true
977
979
  },
978
980
  styles: {
979
981
  justifyContent: {
@@ -517,7 +517,9 @@ declare const _default$O: {
517
517
  Row: _gem_sdk_core.ComponentSetting<RowProps$1>;
518
518
  };
519
519
 
520
- type ColProps$1 = BasePropsWrap<unknown, {
520
+ type ColProps$1 = BasePropsWrap<{
521
+ allowSameHeight?: boolean;
522
+ }, {
521
523
  order?: ObjectDevices<number>;
522
524
  gap?: ObjectDevices<string>;
523
525
  alignItem?: ObjectDevices<Property.AlignItems>;
@@ -537,6 +539,7 @@ type RowProps$1 = BaseProps<{
537
539
  order?: ObjectDevices<number>;
538
540
  inlineAlignment?: 'start' | 'end' | 'center';
539
541
  blockAlignment?: 'start' | 'end' | 'center';
542
+ allowSameHeight?: boolean;
540
543
  }, {
541
544
  fullWidth?: ObjectDevices<boolean>;
542
545
  width?: ObjectDevices<string>;
@@ -5320,7 +5323,9 @@ declare const Coupon: ({ setting, builderProps, builderAttrs, style, styles, adv
5320
5323
  pageContext?: PageContext | undefined;
5321
5324
  }) => string;
5322
5325
 
5323
- type ColProps = BasePropsWrap<unknown, {
5326
+ type ColProps = BasePropsWrap<{
5327
+ allowSameHeight?: boolean;
5328
+ }, {
5324
5329
  order?: ObjectDevices<number>;
5325
5330
  gap?: ObjectDevices<string>;
5326
5331
  alignItem?: ObjectDevices<Property.AlignItems>;
@@ -5345,6 +5350,7 @@ type RowProps = BaseProps<{
5345
5350
  verticalAlign?: ObjectDevices<string>;
5346
5351
  horizontalAlign?: ObjectDevices<string>;
5347
5352
  order?: ObjectDevices<number>;
5353
+ allowSameHeight?: boolean;
5348
5354
  }, {
5349
5355
  fullWidth?: ObjectDevices<boolean>;
5350
5356
  width?: ObjectDevices<string>;
@@ -5478,6 +5484,7 @@ declare const Product: ({ children, setting, styles, style, builderProps, rawChi
5478
5484
  order?: Partial<Record<_gem_sdk_core.NameDevices, number>> | undefined;
5479
5485
  inlineAlignment?: "center" | "end" | "start" | undefined;
5480
5486
  blockAlignment?: "center" | "end" | "start" | undefined;
5487
+ allowSameHeight?: boolean | undefined;
5481
5488
  } & {
5482
5489
  isSection?: boolean | undefined;
5483
5490
  lazy?: boolean | undefined;
@@ -6220,6 +6227,7 @@ declare const HeroBanner: ({ builderAttrs, builderProps, setting, styles, style,
6220
6227
  order?: Partial<Record<NameDevices, number>> | undefined;
6221
6228
  inlineAlignment?: "center" | "end" | "start" | undefined;
6222
6229
  blockAlignment?: "center" | "end" | "start" | undefined;
6230
+ allowSameHeight?: boolean | undefined;
6223
6231
  } & {
6224
6232
  isSection?: boolean | undefined;
6225
6233
  lazy?: boolean | undefined;
@@ -6477,6 +6485,7 @@ declare const CollectionBanner: ({ builderAttrs, builderProps, setting, style, c
6477
6485
  order?: Partial<Record<_gem_sdk_core.NameDevices, number>> | undefined;
6478
6486
  inlineAlignment?: "center" | "end" | "start" | undefined;
6479
6487
  blockAlignment?: "center" | "end" | "start" | undefined;
6488
+ allowSameHeight?: boolean | undefined;
6480
6489
  } & {
6481
6490
  isSection?: boolean | undefined;
6482
6491
  lazy?: boolean | undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gem-sdk/components",
3
- "version": "2.0.0-staging.126",
3
+ "version": "2.0.0-staging.127",
4
4
  "license": "MIT",
5
5
  "sideEffects": false,
6
6
  "main": "dist/cjs/index.js",
@@ -23,7 +23,7 @@
23
23
  },
24
24
  "devDependencies": {
25
25
  "@gem-sdk/core": "2.0.0-staging.117",
26
- "@gem-sdk/styles": "2.0.0-staging.117",
26
+ "@gem-sdk/styles": "2.0.0-staging.127",
27
27
  "@types/react-transition-group": "^4.4.5"
28
28
  },
29
29
  "dependencies": {