> For the complete documentation index, see [llms.txt](https://help.craftsmanplus.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.craftsmanplus.com/play/catalogue/connecting-your-project/content-swapping-logic.md).

# Content Swapping Logic

When a row is loaded at runtime, Catalogue swaps the mapped layer content while preserving the original layer properties from your PLAY project.

***

### **How Swapping Works** <a href="#how-swapping-works" id="how-swapping-works"></a>

**Text Layers:**

* The catalogue text replaces the layer's text content
* The original text box size, position, font family, font size, color, alignment, and styling are preserved
* If the new text is longer than the original, it will wrap or overflow based on the text box configuration in your project

**Image Layers:**

* The catalogue image replaces the layer's image source
* The original layer's position, size, and any applied effects are preserved (just like preforming an image swap).
* Images are scaled to fit the layer bounds as defined in the project

***

This swapping approach means you design your creative once with all the styling, positioning, and effects you want, then use the catalogue purely to swap content. You don't need to redefine fonts, colors, or layouts in the catalogue — those are controlled by your PLAY project.

{% hint style="info" %}
**For example:**

* Your project defines a headline as "Arial Bold, 24pt, Blue, Centered"
* Your catalogue just provides the text: "Play Now", "Jouez Maintenant", "Jugar Ahora"
* At runtime, each translation displays with the same Arial Bold, 24pt, Blue, Centered styling
  {% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://help.craftsmanplus.com/play/catalogue/connecting-your-project/content-swapping-logic.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
