Open sun-mota opened 2 weeks ago
This PR adds the auro-radio component to the project, including both auro-radio and auro-radio-group elements. The implementation includes full accessibility support, form validation, and styling capabilities. The changes primarily involve adding new component files and updating build configurations to support the new radio component.
classDiagram
class AuroRadio {
- Boolean checked
- Boolean disabled
- Boolean required
- Boolean error
- Number tabIndex
- String id
- String label
- String name
- String value
+ handleChange(Event event)
+ handleInput(Event event)
+ handleFocus(Event event)
+ handleBlur(Event event)
+ invalid(Boolean error)
+ isRequired(Boolean required)
+ render()
}
class AuroRadioGroup {
- Boolean disabled
- Boolean horizontal
- Boolean required
- String validity
- String value
- Object optionSelected
+ handleSelection(Event event)
+ handleRadioBlur()
+ reset()
+ handleItems()
+ handleSlotChange()
+ initializeIndex()
+ handleToggleSelected(Event event)
+ selectItem(Number index)
+ selectNextItem(Number index, String moveDirection)
+ handleKeyDown(Event event)
+ render()
}
AuroRadioGroup --> AuroRadio : contains
note for AuroRadio "Represents a single radio button with properties for state and events."
note for AuroRadioGroup "Manages a group of AuroRadio elements, handling selection and validation."
Change | Details | Files |
---|---|---|
Added new auro-radio and auro-radio-group components with full implementation |
|
components/radio/src/auro-radio.js components/radio/src/auro-radio-group.js components/radio/src/style.scss components/radio/src/color.scss components/radio/src/tokens.scss |
Added comprehensive test suite for the radio components |
|
components/radio/test/auro-radio.test.js |
Updated build configuration to support the new radio component |
|
package.json |
Added comprehensive documentation and examples |
|
components/radio/docs/api.md components/radio/demo/api.md components/radio/apiExamples/* |
Issue | Objective | Addressed | Explanation |
---|---|---|---|
#26 | Add radio component to the project | ✅ |
Alaska Airlines Pull Request
close #26
adding
auro-radio@4.1.1
to auro-formkitBy submitting this Pull Request, I confirm that my contribution is made under the terms of the Apache 2.0 license and I have performed a self-review of my own update.
Summary by Sourcery
Add the auro-radio component to the project, complete with build scripts, documentation, and tests, enhancing the form kit with radio button functionality.
New Features:
Enhancements:
Build:
Documentation:
Tests: