InseeFr / Lunatic

Library of questionnaire components
https://inseefr.github.io/Lunatic/
MIT License
20 stars 21 forks source link

fix: Do no render empty declarations #1016

Closed ddecrulle closed 1 month ago

ddecrulle commented 1 month ago

We do not want to render declaration component when there is not label.

Today, this declaration will render a div without text :

{
  "declarations": [
    {
      "label": {
        "type": "VTL|MD",
        "value": '""',
      },
      "position": "BEFORE_QUESTION_TEXT",
    },
  ]
}

This PR resolve this issue https://github.com/InseeFr/Lunatic-DSFR/issues/174

sonarcloud[bot] commented 1 month ago

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarCloud