Issues with "spacing' field "visibility" property during module update via Design Tools

Hi, I am developing a custom module locally. In the ‘Style’ tab, there is a “spacing” field. I only need the margin value, so I added a “visibility” property to hide the padding property.

}, {
 "id" : "b0f4f8db-df83-4d74-e6db-285cb0b2bb47",
 "name" : "decor_spacing",
 "display_width" : null,
 "label" : "Decor spacing",
 "required" : false,
 "locked" : false,
 "children" : [ {
 "id" : "15c205fa-8537-4ab2-11f2-5be0b989b06c",
 "name" : "spacing_field_1",
 "display_width" : null,
 "label" : "Spacing",
 "required" : false,
 "locked" : false,
 "type" : "spacing",
 "visibility": {
 "hidden_subfields": {
 "padding": true
 }
 },
 "default" : { }
 } ],
 "tab" : "STYLE",
 "expanded" : false,
 "type" : "group",
 "default" : { }
 }, {

After that, I upload it using “hs upload”, and everything works fine. However, when I add new fields in the Design Tools to the “Style” tab, the “visibility” property gets removed. I have to do “hs fetch” and add it again:(
Please advise on what I am doing wrong or what might be the reason for it getting deleted when I update the module through design tools.
Many thanks in advance

I believe this is just a limitation of the Design Tools. Display conditions in Design Tools do not have the option to hide subfields, essentially it’s a code-only option. Therefore when you edit the module in Design Tools it’s rewriting the code to what is available in that platform. The only option here would be - don’t use Design Tools. :sweat_smile:

thanks) looks like, yeah, do not use design tools the better solution:)