lizhimins commented on PR #7305:
URL:
https://github.com/apache/rocketmq-dashboard/pull/7305#issuecomment-6434927898
Closing this one for now - the underlying defect and the tests are sound,
and a resubmission that clears the two points below is welcome.
1. The live regions are not actually created before the first toast. Your
module doc states the invariant explicitly ("The containers are created once,
before any toast can fire, because a live region that appears in the same
update as its content is not reliably announced"), but the mount effect in
`StudioApp.tsx` only calls `message.config({ getContainer: getMessageLiveRegion
})` - it never invokes the getters. `ensureLiveRegion` therefore runs the first
time antd needs a container, which is the same update that inserts the first
toast: exactly the case the doc says is not reliably announced. Create both
regions in the mount effect and keep the getters as the lookup path.
2. The `it()` names end in `Test` (`...per toast kindTest`, `...through the
live regionTest`). The frontend suites in this repo use sentence-style
descriptions; the `Test` suffix is the Java convention here.
Neither is a large change, so please do send it back if you pick it up again.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]