Fix block/inline Element descendants error noise in NewRoomIntro.tsx (#10412)

Error before:
```
Warning: validateDOMNesting(...): <div> cannot appear as a descendant of <p>.
    at div
    at AccessibleButton (webpack-internal:///470:43:7)
    at span
    at p
    at li
    at NewRoomIntro (webpack-internal:///2063:77:71)
    at ol
    at div
    at div
    at AutoHideScrollbar (webpack-internal:///1020:37:5)
    at ScrollPanel (webpack-internal:///1106:69:5)
    at ErrorBoundary (webpack-internal:///2070:47:5)
    at MessagePanel (webpack-internal:///2060:169:5)
    at TimelinePanel (webpack-internal:///2095:113:5)
    at div
    at div
    at div
    at MainSplit (webpack-internal:///2019:31:5)
    at ErrorBoundary (webpack-internal:///2070:47:5)
    at main
    at RoomView (webpack-internal:///2018:330:5)
    at div
    at div
    at div
    at LoggedInView (webpack-internal:///1907:130:5)
    at ErrorBoundary (webpack-internal:///2070:47:5)
    at MatrixChat (webpack-internal:///1900:234:5)
```
pull/28217/head
Eric Eastwood 2023-03-21 10:55:48 -05:00 committed by GitHub
parent ef68650594
commit f7fe0e9d8b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -141,7 +141,7 @@ const NewRoomIntro: React.FC = () => {
{ topic },
{
a: (sub) => (
<AccessibleButton kind="link_inline" onClick={onTopicClick}>
<AccessibleButton element="a" kind="link_inline" onClick={onTopicClick}>
{sub}
</AccessibleButton>
),
@ -155,7 +155,7 @@ const NewRoomIntro: React.FC = () => {
{},
{
a: (sub) => (
<AccessibleButton kind="link_inline" onClick={onTopicClick}>
<AccessibleButton element="a" kind="link_inline" onClick={onTopicClick}>
{sub}
</AccessibleButton>
),