space10-community / conversational-form

Turning web forms into conversations
https://space10-community.github.io/conversational-form/
MIT License
3.8k stars 777 forks source link

Conditional not working #405

Closed mbhassan closed 4 years ago

mbhassan commented 4 years ago

Confused AF as to how to work this

{
      "tag": "fieldset",
      "type": "radio",
      "cf-questions": "q1",
      "children": [
        {
          "tag": "input",
          "type": "radio",
          "name": "city",
          "cf-label": "a"
        },
        {
          "tag": "input",
          "type": "radio",
          "name": "city",
          "cf-label": "b"
        }
      ]
    },
    {
      "tag": "fieldset",
      "type": "radio",
      "cf-questions": "boo",
      "cf-conditional-city": "b",
      "children": [
        {
          "tag": "option",
          "type": "radio",
          "name": "loc",
          "value": "c",
          "cf-label": "c"
        },
        {
          "tag": "option",
          "type": "radio",
          "name": "loc",
          "value": "d",
          "cf-label": "d"
        }
      ]
    }
mbhassan commented 4 years ago

found solution by removing from set

mtness commented 2 years ago

and how does your soution look like? I'm struggling with the same setup - any idea would be greatly appreciated!