Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BD-3340 Update catalog Liquid #7831

Merged
merged 3 commits into from
Aug 9, 2024
Merged

BD-3340 Update catalog Liquid #7831

merged 3 commits into from
Aug 9, 2024

Conversation

rachel-feinberg
Copy link
Contributor

Summary

Corrects Liquid and adds details to selection criteria

Related PRs, issues, or features (optional)

#BD-3340

Feature release date (optional)

  • N/A

Contributor checklist

  • I confirm that my PR meets the following:
    • I signed the Contribution License Agreement (CLA).
    • My style and voice follows the Braze Style Guide.
    • My content contains correct spelling and grammar.
    • All links are working correctly.
    • If I renamed or moved a file or directory, I set up URL redirects for each file.
    • If I updated or replaced an image, I did not remove the original image file from the repository. (For more information, see Updating an image).
    • If my PR is related to a paid SKU, third party, SMS, AI, or privacy, I have received written approval from Braze Legal.

Submitting for review

If your PR meets the above requirements, select Ready for review, then add a reviewer:

  • Non-Braze contributors: Add braze-inc/docs-team as the reviewer.
  • Braze employees: Have any relevant subject matter experts (like engineers or product managers) review your work first, then add the tech writer assigned to your specific vertical. If you're not sure which tech writer to add, you can add braze-inc/docs-team instead.

Thanks for contributing! We look forward to reading your work.

@rachel-feinberg rachel-feinberg self-assigned this Aug 7, 2024
@cla-bot cla-bot bot added the cla-signed label Aug 7, 2024
Copy link
Contributor

@lydia-xie lydia-xie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm!

@@ -247,15 +247,15 @@ Do that
```
{% endraw %}

Note that you must declare the catalog list before using `if` statements. In the example above, `Test-list` is the catalog list.
You must declare the catalog list before using `if` statements. In the example above, `Test-list` is the catalog list.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure what a "catalog list" is but this is "test-list" is the name of a catalog.

@@ -266,6 +266,8 @@ Message if the venue name's size is less than 10 characters.
```
{% endraw %}

Note that this scenario uses `catalog_selection_items` instead of `catalog_items`. This is because we're pulling items from a [selection]({{site.baseurl}}/user_guide/personalization_and_dynamic_content/catalogs/selections/), where `venue-list` is the catalog name and `venue_selection` is the selection.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This makes sense


#### Use case: Liquid `if` snippet

In this scenario, different messages will display if the custom attribute `venue_name` has more then 10 characters or less then 10 characters. If `venue_name` is `blank`, nothing will display.

{% raw %}
```liquid
{% catalog_selection_items item-list selections %}
{% catalog_selection_items venue-list venue_selection %}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants