# Elements and ai creating properties

**URL:** <https://forums.realmacsoftware.com/t/elements-and-ai-creating-properties/45060>\
**Category:** Elements API\
**Created:** [October 26, 2024, 4:49pm UTC](https://forums.realmacsoftware.com/t/elements-and-ai-creating-properties/45060 "2024-10-26T16:49:58Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![upssjw](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/upssjw/32/26063_2.png) [@upssjw](https://forums.realmacsoftware.com/u/upssjw)\
**Post date:** [October 26, 2024, 4:49pm UTC](https://forums.realmacsoftware.com/t/elements-and-ai-creating-properties/45060/1 "2024-10-26T16:49:58Z")

</div>

chatgtp showed it a slider property and background color then asked to write the code display what is on screen not exactly what I wanted but seemed to understand properties

---

<div class="post-metadata">

**Author:** ![dan](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/dan/32/28516_2.png) [@dan](https://forums.realmacsoftware.com/u/dan)\
**Post date:** [October 26, 2024, 5:22pm UTC](https://forums.realmacsoftware.com/t/elements-and-ai-creating-properties/45060/2 "2024-10-26T17:22:59Z")

</div>

Oh interesting… so you showed it the properties JSON code? and asked it to generate the HTML for the Template?

---

<div class="post-metadata">

**Author:** ![Bartje](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/bartje/32/1210_2.png) [@Bartje](https://forums.realmacsoftware.com/u/Bartje)\
**Post date:** [October 26, 2024, 5:37pm UTC](https://forums.realmacsoftware.com/t/elements-and-ai-creating-properties/45060/3 "2024-10-26T17:37:51Z")

</div>

That’s how I did it to make my Google Sheet component. Just asked chatGTP how I could import from Google Sheets into a custom component in Elements and told that a CC has a template, Styles, Javascript, Hooks and Properties section. ChatGTP seems to understand how it works. It created the Json code and the HTML code for the Template. Just had to give the link to the manual so it understood it had to use groups for the properties. 📚 🧑‍🎓

---

<div class="post-metadata">

**Author:** ![upssjw](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/upssjw/32/26063_2.png) [@upssjw](https://forums.realmacsoftware.com/u/upssjw)\
**Post date:** [October 26, 2024, 6:04pm UTC](https://forums.realmacsoftware.com/t/elements-and-ai-creating-properties/45060/4 "2024-10-26T18:04:52Z")

</div>

yes showed it once and it wrote the rest, I told it that they couldn’t be the same. as they were variables, it the created the rest, I also showed it the colour version, told it to put one square in another and use relative and absolute, I could have written self but just wanted to see if it could work it out not exposed any more json,

---

<div class="post-metadata">

**Author:** ![upssjw](https://dub1.discourse-cdn.com/flex005/user_avatar/forums.realmacsoftware.com/upssjw/32/26063_2.png) [@upssjw](https://forums.realmacsoftware.com/u/upssjw)\
**Post date:** [October 26, 2024, 6:09pm UTC](https://forums.realmacsoftware.com/t/elements-and-ai-creating-properties/45060/5 "2024-10-26T18:09:37Z")

</div>

I wrote it and messed the code up a bit but chat pointed it out I messed up the px format

**Duplicate Titles:** Changed the second “Height” title to “Width” to avoid duplication.

1. **JSON Format:** Fixed issues with quotation marks to ensure valid JSON.

2. **Units:** Changed “p”x to “px” for consistency in units.

3. **Array Structure:** Wrapped the objects in an array to allow for multiple properties.
