Skip to content

Commit

Permalink
Introduces standardMetafieldDependencies prop
Browse files Browse the repository at this point in the history
Removes extra *

Adds changeset

Switches to singular
  • Loading branch information
loic-d committed Feb 28, 2023
1 parent fa57c5d commit 0c5b0d5
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 5 deletions.
6 changes: 6 additions & 0 deletions .changeset/sweet-ways-hunt.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
'@shopify/ui-extensions': patch
'@shopify/ui-extensions-react': patch
---

Introduces standardMetafieldDependencies prop on CustomerSegmentationTemplate
Original file line number Diff line number Diff line change
Expand Up @@ -21,17 +21,25 @@ type Source =
| 'buyButtonMajor'
| 'followUpEmailMajor';

/**
* Reserved namespace and key for the customer standard metafield used in the template's query.
* More info - https://shopify.dev/docs/apps/custom-data/metafields/definitions/standard
*/
type CustomerStandardMetafieldDependency = 'facts.birth_date';

export interface CustomerSegmentationTemplateProps {
/** Localized title of the template. */
/* Localized title of the template. */
title: string;
/** Localized description of the template. */
/* Localized description of the template. */
description: string;
/** Icon identifier for the template. This property is ignored for non-1P Segmentation templates as we fallback to the app icon */
/* Icon identifier for the template. This property is ignored for non-1P Segmentation templates as we fallback to the app icon */
icon?: Source;
/** ShopifyQL code snippet to render in the template with syntax highlighting **/
/* ShopifyQL code snippet to render in the template with syntax highlighting */
templateQuery: string;
/** ShopifyQL code snippet to insert in the segment editor. If missing, `templateQuery` will be used. */
/* ShopifyQL code snippet to insert in the segment editor. If missing, `templateQuery` will be used. */
templateQueryToInsert?: string;
/* List of customer standard metafield used in the template's query */
standardMetafieldDependencies?: CustomerStandardMetafieldDependency[];
}

/**
Expand Down

0 comments on commit 0c5b0d5

Please sign in to comment.