From 41ff8db2f5a9f858f4f5aebc90c56914e2afb99b Mon Sep 17 00:00:00 2001 From: Dylan <36567925+Airyzz@users.noreply.github.com> Date: Thu, 14 Jul 2022 20:02:55 +0930 Subject: [PATCH] Fix code style --- .../confirm-dialog/ConfirmDialog.jsx | 7 +- src/app/molecules/dialog/ReusableDialog.jsx | 6 +- .../following-members/FollowingMembers.jsx | 14 +- .../molecules/image-upload/ImageUpload.jsx | 8 +- .../ExportE2ERoomKeys.jsx | 16 +- .../ImportE2ERoomKeys.jsx | 18 +- src/app/molecules/media/Media.jsx | 13 +- src/app/molecules/message/Message.jsx | 63 ++++--- .../molecules/popup-window/PopupWindow.jsx | 6 +- .../PowerLevelSelector.jsx | 6 +- .../molecules/room-aliases/RoomAliases.jsx | 49 +++--- .../room-encryption/RoomEncryption.jsx | 17 +- .../RoomHistoryVisibility.jsx | 9 +- .../molecules/room-members/RoomMembers.jsx | 16 +- .../room-notification/RoomNotification.jsx | 5 +- .../molecules/room-options/RoomOptions.jsx | 20 +-- .../room-permissions/RoomPermissions.jsx | 4 +- .../molecules/room-profile/RoomProfile.jsx | 43 ++--- src/app/molecules/room-search/RoomSearch.jsx | 24 +-- src/app/molecules/room-tile/RoomTile.jsx | 10 +- .../room-visibility/RoomVisibility.jsx | 4 +- .../space-add-existing/SpaceAddExisting.jsx | 27 +-- .../molecules/space-options/SpaceOptions.jsx | 22 +-- src/app/molecules/sso-buttons/SSOButtons.jsx | 8 +- src/app/organisms/create-room/CreateRoom.jsx | 52 +++--- src/app/organisms/drag-drop/DragDrop.jsx | 8 +- .../emoji-verification/EmojiVerification.jsx | 25 +-- src/app/organisms/invite-list/InviteList.jsx | 25 ++- src/app/organisms/invite-user/InviteUser.jsx | 43 +++-- src/app/organisms/join-alias/JoinAlias.jsx | 26 +-- .../organisms/navigation/DrawerBreadcrumb.jsx | 8 +- src/app/organisms/navigation/DrawerHeader.jsx | 27 ++- src/app/organisms/navigation/Selector.jsx | 6 +- src/app/organisms/navigation/SideBar.jsx | 24 +-- .../profile-editor/ProfileEditor.jsx | 20 +-- .../profile-viewer/ProfileViewer.jsx | 44 ++--- .../organisms/public-rooms/PublicRooms.jsx | 43 +++-- src/app/organisms/room/PeopleDrawer.jsx | 18 +- src/app/organisms/room/RoomSettings.jsx | 30 ++-- src/app/organisms/room/RoomViewContent.jsx | 40 +++-- src/app/organisms/room/RoomViewFloating.jsx | 42 +++-- src/app/organisms/room/RoomViewHeader.jsx | 12 +- src/app/organisms/room/RoomViewInput.jsx | 24 ++- src/app/organisms/room/common.jsx | 158 ++++++++---------- src/app/organisms/search/Search.jsx | 10 +- src/app/organisms/settings/AuthRequest.jsx | 2 +- src/app/organisms/settings/CrossSigning.jsx | 2 +- src/app/organisms/settings/DeviceManage.jsx | 57 ++++--- src/app/organisms/settings/KeyBackup.jsx | 2 +- .../settings/SecretStorageAccess.jsx | 16 +- src/app/organisms/settings/Settings.jsx | 76 ++++----- .../shortcut-spaces/ShortcutSpaces.jsx | 23 ++- .../organisms/space-manage/SpaceManage.jsx | 47 +++--- .../space-settings/SpaceSettings.jsx | 32 ++-- src/app/organisms/view-source/ViewSource.jsx | 12 +- src/app/organisms/welcome/Welcome.jsx | 7 +- src/client/action/auth.js | 4 +- src/util/cryptE2ERoomKeys.js | 9 +- src/util/matrixUtil.js | 4 +- 59 files changed, 689 insertions(+), 704 deletions(-) diff --git a/src/app/molecules/confirm-dialog/ConfirmDialog.jsx b/src/app/molecules/confirm-dialog/ConfirmDialog.jsx index da8f60e1..2e4f8ee9 100644 --- a/src/app/molecules/confirm-dialog/ConfirmDialog.jsx +++ b/src/app/molecules/confirm-dialog/ConfirmDialog.jsx @@ -2,25 +2,24 @@ import React from 'react'; import PropTypes from 'prop-types'; import './ConfirmDialog.scss'; +import { useTranslation } from 'react-i18next'; import { openReusableDialog } from '../../../client/action/navigation'; import Text from '../../atoms/text/Text'; import Button from '../../atoms/button/Button'; -import '../../i18n.jsx' -import { useTranslation } from 'react-i18next'; +import '../../i18n'; function ConfirmDialog({ desc, actionTitle, actionType, onComplete, }) { - const { t } = useTranslation(); return (