NO BUG: Bricks.min.js changes 'required' attribute instead of 'checked' on input

Browser: any
OS: Windows
URL: example

bricks.min.js changes required attribute instead of checked on input in checkbox, most likely by this part

function(n) {
  var r = t.getAttribute("name"),
    i = bricksQuerySelectorAll(e, 'input[name="'.concat(r, '"]')),
    o = !1;
  i.forEach((function(e) {
    !0 === e.checked && (o = !0)
  })), o ? i.forEach((function(e) {
    e.required = !1
  })) : i.forEach((function(e) {
    e.required = !0
  }))
}

Hello @Illarion,

I’m not sure what you mean by “changes required attribute”, and what is the bug here. Can you record a video, where you explain and show the issue?

Thank you.
Matej

https://jam.dev/c/5f3f9dbf-9a14-4fec-a5f9-fa55d2e6e656

Aha, I see what you mean. I believe that you toggled that this field is required, right?

The reason why we toggle “required” is that you can have multiple checkboxes. And once you check one of them, we remove the “required” attribute from all of the checkboxes in the same group.
You can see this if you add another “line” to the checkbox control. We don’t toggle the “checked” attribute, and this is the default behavior, even without Bricks. Take a look at this example:
https://mmhms6.csb.app/

I’ll mark this topic as NO BUG.

Matej