Fix css issue in room rights

This commit is contained in:
Bill 2022-03-16 13:58:11 -04:00
parent ca21e833c8
commit a26084b976
2 changed files with 15 additions and 14 deletions

View File

@ -52,8 +52,7 @@
width: 400px; width: 400px;
.list-container { .list-container {
min-height: 100px; height: 100px;
max-height: 100px;
.list-item { .list-item {
background-color: $grid-active-bg-color; background-color: $grid-active-bg-color;

View File

@ -23,22 +23,24 @@ export const NavigatorRoomSettingsRightsTabView: FC<NavigatorRoomSettingsTabView
}, [ roomSettingsData, handleChange ]); }, [ roomSettingsData, handleChange ]);
return ( return (
<Grid overflow="auto"> <Grid>
<Column size={ 6 }> <Column size={ 6 }>
<Text bold> <Text bold>
{ LocalizeText('navigator.flatctrls.userswithrights', [ 'displayed', 'total' ], [ roomSettingsData.usersWithRights.size.toString(), roomSettingsData.usersWithRights.size.toString() ]) } { LocalizeText('navigator.flatctrls.userswithrights', [ 'displayed', 'total' ], [ roomSettingsData.usersWithRights.size.toString(), roomSettingsData.usersWithRights.size.toString() ]) }
</Text> </Text>
<Column fullWidth className="bg-white rounded list-container p-2" overflow="auto" gap={ 1 }> <Flex overflow="hidden" className="bg-white rounded list-container p-2">
{ Array.from(roomSettingsData.usersWithRights.entries()).map(([id, name], index) => <Column fullWidth overflow="auto" gap={ 1 }>
{ { Array.from(roomSettingsData.usersWithRights.entries()).map(([id, name], index) =>
return ( {
<Flex key={ index } alignItems="center" gap={ 1 } overflow="hidden"> return (
<UserProfileIconView userName={ name } /> <Flex key={ index } shrink alignItems="center" gap={ 1 } overflow="hidden">
<Text pointer grow key={index} onClick={ event => removeUserRights(id) }> { name }</Text> <UserProfileIconView userName={ name } />
</Flex> <Text pointer grow key={index} onClick={ event => removeUserRights(id) }> { name }</Text>
); </Flex>
}) } );
</Column> }) }
</Column>
</Flex>
<Button variant="danger" disabled={ !roomSettingsData.usersWithRights.size } onClick={ removeAllRights } > <Button variant="danger" disabled={ !roomSettingsData.usersWithRights.size } onClick={ removeAllRights } >
{ LocalizeText('navigator.flatctrls.clear') } { LocalizeText('navigator.flatctrls.clear') }
</Button> </Button>