Date value mismatch between GoAInputDateTime component and its onChange event
Info
Issue created by Paul Li
When using the GoAInputDateTime component, if you select anything except seconds, the seconds will be set to 00, despite sending the actual value in the onChange. After that, the onChange will start sending back 00 for the seconds value.
This issue only happens with React and only with goa components, no issue exists with goab components.
Code
const [date, setDate] = useState<Date | string>("");
<GoAInputDateTime
name={'ADSP test'}
value={date}
onChange={(name, value: Date | string) => {
setDate(value);
console.log(value);
}}
/>
Reproduction Steps
- Open the GoAInputDateTime component.
- Set the seconds to a value
- Close the component.
The seconds will be changed to 00, despite sending the value you set in the console log.
@ArakTaiRoth Talk to Paul regarding the effect on the product
:tada: This issue has been resolved in version 5.5.1 :tada:
The release is available on:
Your semantic-release bot :package::rocket:
The PR was merged to LTS