FuelLabs / fuel-ui

Fuel design system
https://design.fuel.network
Apache License 2.0
85 stars 29 forks source link

fix: call onClose when drawer should close #207

Closed luizstacio closed 1 year ago

luizstacio commented 1 year ago

When using the outside state to control isOpen on the drawer, it was impossible to receive the onClose callback to change the state.

This PR fixes it by calling onClose when the state should change to close but is up to the upper state controller to change the state to close as expected.

github-actions[bot] commented 1 year ago

Coverage report for ./design-system/react

St.:grey_question:
Category Percentage Covered / Total
🟒 Statements 93.57% 1658/1772
🟒 Branches 83.49% 364/436
🟒 Functions 83.83% 223/266
🟒 Lines 94.1% 1628/1730

Test suite run success

147 tests passing in 47 suites.

Report generated by πŸ§ͺjest coverage report action from 7167d31ba0a5f6095fe2c62c078cdbf8e6486677