Fix issues with the Create new room button in Spotlight (#8851)

* Correct label of create new room button
* Capitalize suggested name for new room
pull/28217/head
Janne Mareike Koschinski 2022-06-15 18:16:40 +02:00 committed by GitHub
parent 1188f1a508
commit f9100d5fb6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 5 deletions

View File

@ -15,7 +15,7 @@ limitations under the License.
*/
import classNames from "classnames";
import { sum } from "lodash";
import { capitalize, sum } from "lodash";
import { WebSearch as WebSearchEvent } from "@matrix-org/analytics-events/types/typescript/WebSearch";
import { IHierarchyRoom } from "matrix-js-sdk/src/@types/spaces";
import { IPublicRoomsChunkRoom, MatrixClient, RoomMember } from "matrix-js-sdk/src/matrix";
@ -741,11 +741,11 @@ const SpotlightDialog: React.FC<IProps> = ({ initialText = "", initialFilter = n
onClick={() => defaultDispatcher.dispatch({
action: 'view_create_room',
public: true,
defaultName: trimmedQuery,
defaultName: capitalize(trimmedQuery),
})}
>
<span className="mx_AccessibleButton mx_AccessibleButton_hasKind mx_AccessibleButton_kind_primary_outline">
{ _t("Create new Room") }
{ _t("Create new room") }
</span>
</Option>
</div>

View File

@ -2810,7 +2810,7 @@
"Copy invite link": "Copy invite link",
"Some results may be hidden": "Some results may be hidden",
"If you can't find the room you're looking for, ask for an invite or create a new room.": "If you can't find the room you're looking for, ask for an invite or create a new room.",
"Create new Room": "Create new Room",
"Create new room": "Create new room",
"Other options": "Other options",
"Start a group chat": "Start a group chat",
"Other searches": "Other searches",
@ -3082,7 +3082,6 @@
"remove %(name)s from the directory.": "remove %(name)s from the directory.",
"delete the address.": "delete the address.",
"The server may be unavailable or overloaded": "The server may be unavailable or overloaded",
"Create new room": "Create new room",
"No results for \"%(query)s\"": "No results for \"%(query)s\"",
"Try different words or check for typos. Some results may not be visible as they're private and you need an invite to join them.": "Try different words or check for typos. Some results may not be visible as they're private and you need an invite to join them.",
"Find a room…": "Find a room…",