From fd64d37305c35022586fc1a8a677a3f1aea74eaa Mon Sep 17 00:00:00 2001 From: Michael Telatynski <7t3chguy@gmail.com> Date: Wed, 21 Jul 2021 11:20:41 +0100 Subject: [PATCH] Add iconography to Create Room Dialog dropdown Remove unused old stale feather-customised/globe.svg --- res/css/views/dialogs/_CreateRoomDialog.scss | 38 +++++++++++++++++++ res/img/feather-customised/globe.svg | 7 ---- .../views/dialogs/CreateRoomDialog.tsx | 6 +-- .../ManageRestrictedJoinRuleDialog.tsx | 2 +- .../tabs/room/SecurityRoomSettingsTab.tsx | 2 +- src/i18n/strings/en_EN.json | 6 +-- src/stores/SpaceStore.tsx | 2 +- 7 files changed, 47 insertions(+), 16 deletions(-) delete mode 100644 res/img/feather-customised/globe.svg diff --git a/res/css/views/dialogs/_CreateRoomDialog.scss b/res/css/views/dialogs/_CreateRoomDialog.scss index adba58cbb9..173256f8af 100644 --- a/res/css/views/dialogs/_CreateRoomDialog.scss +++ b/res/css/views/dialogs/_CreateRoomDialog.scss @@ -120,6 +120,44 @@ limitations under the License. .mx_Dropdown_input { border: 1px solid $input-border-color; } + + .mx_Dropdown_option { + font-size: $font-14px; + line-height: $font-32px; + height: 32px; + + > div { + padding-left: 30px; + position: relative; + + &::before { + content: ""; + position: absolute; + height: 16px; + width: 16px; + left: 6px; + top: 8px; + mask-repeat: no-repeat; + mask-position: center; + background-color: $secondary-fg-color; + } + } + } + + .mx_CreateRoomDialog_dropdown_invite::before { + mask-image: url('$(res)/img/element-icons/lock.svg'); + mask-size: contain; + } + + .mx_CreateRoomDialog_dropdown_public::before { + mask-image: url('$(res)/img/globe.svg'); + mask-size: 12px; + } + + .mx_CreateRoomDialog_dropdown_restricted::before { + mask-image: url('$(res)/img/element-icons/community-members.svg'); + mask-size: contain; + } } } diff --git a/res/img/feather-customised/globe.svg b/res/img/feather-customised/globe.svg deleted file mode 100644 index 8af7dc41dc..0000000000 --- a/res/img/feather-customised/globe.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/src/components/views/dialogs/CreateRoomDialog.tsx b/src/components/views/dialogs/CreateRoomDialog.tsx index db0b48f71c..b5d8421ae0 100644 --- a/src/components/views/dialogs/CreateRoomDialog.tsx +++ b/src/components/views/dialogs/CreateRoomDialog.tsx @@ -322,16 +322,16 @@ export default class CreateRoomDialog extends React.Component { } const options = [ -
+
{ _t("Private room (invite only)") }
, -
+
{ _t("Public room") }
, ]; if (this.supportsRestricted) { - options.unshift(
+ options.unshift(
{ _t("Visible to space members") }
); } diff --git a/src/components/views/dialogs/ManageRestrictedJoinRuleDialog.tsx b/src/components/views/dialogs/ManageRestrictedJoinRuleDialog.tsx index ff08ae5d28..9d571a8ed6 100644 --- a/src/components/views/dialogs/ManageRestrictedJoinRuleDialog.tsx +++ b/src/components/views/dialogs/ManageRestrictedJoinRuleDialog.tsx @@ -117,7 +117,7 @@ const ManageRestrictedJoinRuleDialog: React.FC = ({ room, selected = [], >

{ _t("Decide which spaces can access this room. " + - "If a space is selected its members will be able to find and join .", {}, { + "If a space is selected, its members can find and join .", {}, { RoomName: () => { room.name }, })}

diff --git a/src/components/views/settings/tabs/room/SecurityRoomSettingsTab.tsx b/src/components/views/settings/tabs/room/SecurityRoomSettingsTab.tsx index 312b8d84f5..0b29e18103 100644 --- a/src/components/views/settings/tabs/room/SecurityRoomSettingsTab.tsx +++ b/src/components/views/settings/tabs/room/SecurityRoomSettingsTab.tsx @@ -419,7 +419,7 @@ export default class SecurityRoomSettingsTab extends React.Component
- { _t("Decide who can view and join %(roomName)s.", { + { _t("Decide who can join %(roomName)s.", { roomName: client.getRoom(this.props.roomId)?.name, }) }
diff --git a/src/i18n/strings/en_EN.json b/src/i18n/strings/en_EN.json index 2dce7055f6..554e8a7d9b 100644 --- a/src/i18n/strings/en_EN.json +++ b/src/i18n/strings/en_EN.json @@ -772,7 +772,7 @@ "General": "General", "Security & Privacy": "Security & Privacy", "Roles & Permissions": "Roles & Permissions", - "This make it easy for rooms to stay private to a space, while letting people in the space find and join them. All new rooms in a space will have this option available.": "This make it easy for rooms to stay private to a space, while letting people in the space find and join them. All new rooms in a space will have this option available.", + "This makes it easy for rooms to stay private to a space, while letting people in the space find and join them. All new rooms in a space will have this option available.": "This makes it easy for rooms to stay private to a space, while letting people in the space find and join them. All new rooms in a space will have this option available.", "Skip": "Skip", "You joined the call": "You joined the call", "%(senderName)s joined the call": "%(senderName)s joined the call", @@ -1440,7 +1440,7 @@ "Anyone in %(spaceName)s can find and join. You can select other spaces too.": "Anyone in %(spaceName)s can find and join. You can select other spaces too.", "Anyone in a space can find and join. You can select multiple spaces.": "Anyone in a space can find and join. You can select multiple spaces.", "Space members": "Space members", - "Decide who can view and join %(roomName)s.": "Decide who can view and join %(roomName)s.", + "Decide who can join %(roomName)s.": "Decide who can join %(roomName)s.", "Members only (since the point in time of selecting this option)": "Members only (since the point in time of selecting this option)", "Members only (since they were invited)": "Members only (since they were invited)", "Members only (since they joined)": "Members only (since they joined)", @@ -2365,7 +2365,7 @@ "%(count)s rooms|one": "%(count)s room", "You're removing all spaces. Access will default to invite only": "You're removing all spaces. Access will default to invite only", "Select spaces": "Select spaces", - "Decide which spaces can access this room. If a space is selected its members will be able to find and join .": "Decide which spaces can access this room. If a space is selected its members will be able to find and join .", + "Decide which spaces can access this room. If a space is selected, its members can find and join .": "Decide which spaces can access this room. If a space is selected, its members can find and join .", "Search spaces": "Search spaces", "Spaces you know that contain this room": "Spaces you know that contain this room", "Other spaces or rooms you might not know": "Other spaces or rooms you might not know", diff --git a/src/stores/SpaceStore.tsx b/src/stores/SpaceStore.tsx index 6f03c6002f..a1ee9df4e5 100644 --- a/src/stores/SpaceStore.tsx +++ b/src/stores/SpaceStore.tsx @@ -232,7 +232,7 @@ export class SpaceStoreClass extends AsyncStoreWithClient {
-

{ _t("This make it easy for rooms to stay private to a space, " + +

{ _t("This makes it easy for rooms to stay private to a space, " + "while letting people in the space find and join them. " + "All new rooms in a space will have this option available.")}

,