Eslint updates

This commit is contained in:
Bill 2022-04-03 20:51:59 -04:00
parent 91673959b9
commit 9a8503f68e
6 changed files with 12 additions and 6 deletions

View File

@ -1,4 +1,5 @@
{
"root": true,
"settings": {
"react": {
"pragma": "React",
@ -32,8 +33,13 @@
"@typescript-eslint/indent": [ "error", 4, { "SwitchCase": 1 } ],
"array-bracket-spacing": [ "error", "always" ],
"brace-style": [ "error", "allman" ],
"template-curly-spacing": [ "error", "always" ],
"no-multi-spaces": [ "error" ],
"react/prop-types": [ "off" ],
"object-curly-spacing": [ "error", "always" ],
"jsx-quotes": [ "error" ],
"react/jsx-curly-spacing": [ "error", "always" ],
"react/jsx-equals-spacing": [ "error" ],
"@typescript-eslint/object-curly-spacing": [ "error", "always", { "arraysInObjects": true, "objectsInObjects": false } ],
"@typescript-eslint/ban-types": [
"error",
{

View File

@ -30,5 +30,5 @@ export const LayoutFurniIconImageView: FC<LayoutFurniIconImageViewProps> = props
return imageUrl;
}
return <LayoutImage imageUrl={ getImageIconUrl() } className='furni-image' { ...rest } />;
return <LayoutImage imageUrl={ getImageIconUrl() } className="furni-image" { ...rest } />;
}

View File

@ -57,7 +57,7 @@ export const FriendsMessengerThreadGroup: FC<{ thread: MessengerThread, group: M
<LayoutAvatarImageView figure={ groupChatData.figure } direction={ 2 } /> }
</Base>
<Base className={ 'bg-light text-black border-radius mb-2 rounded py-1 px-2 messages-group-' + (isOwnChat ? 'right' : 'left') }>
<Base className='fw-bold'>
<Base className="fw-bold">
{ isOwnChat && GetSessionDataManager().userName }
{ !isOwnChat && (groupChatData ? groupChatData.username : thread.participant.name) }
</Base>

View File

@ -225,7 +225,7 @@ export const NavigatorView: FC<{}> = props =>
<FontAwesomeIcon icon="plus" />
</NitroCardTabsItemView>
</NitroCardTabsView>
<NitroCardContentView position='relative'>
<NitroCardContentView position="relative">
{ isLoading &&
<Base fit position="absolute" className="top-0 start-0 z-index-1 bg-muted opacity-0-5" /> }
{ !isCreatorOpen &&

View File

@ -91,7 +91,7 @@ export const NavigatorSearchResultItemView: FC<NavigatorSearchResultItemViewProp
{ (roomData.doorMode !== RoomDataParser.OPEN_STATE) &&
<i className={ ('position-absolute end-0 mb-1 me-1 icon icon-navigator-room-' + ((roomData.doorMode === RoomDataParser.DOORBELL_STATE) ? 'locked' : (roomData.doorMode === RoomDataParser.PASSWORD_STATE) ? 'password' : (roomData.doorMode === RoomDataParser.INVISIBLE_STATE) ? 'invisible' : '')) } /> }
</LayoutRoomThumbnailView>
<Flex className='w-100'>
<Flex className="w-100">
<Text truncate className="flex-grow-1">{roomData.roomName}</Text>
<Flex reverse alignItems="center" gap={ 1 }>
<NavigatorSearchResultItemInfoView roomData={ roomData } />

View File

@ -61,7 +61,7 @@ export const NavigatorSearchResultView: FC<NavigatorSearchResultViewProps> = pro
{
gridHasTwoColumns ? <AutoGrid columnCount={ 3 } { ...rest } columnMinWidth={ 110 } columnMinHeight={ 130 } className="mx-2">
{searchResult.rooms.length > 0 && searchResult.rooms.map((room, index) => <NavigatorSearchResultItemView key={ index } roomData={ room } thumbnail={ true } />) }
</AutoGrid> : <Grid columnCount={ 1 } className='navigator-grid' gap={ 0 }>
</AutoGrid> : <Grid columnCount={ 1 } className="navigator-grid" gap={ 0 }>
{ searchResult.rooms.length > 0 && searchResult.rooms.map((room, index) => <NavigatorSearchResultItemView key={ index } roomData={ room } />) }
</Grid>
}