Remove svg usage for user status (#1486)

* Remove SVG usage for status indicators to speedup channel loading

* Add needed assets for status icons (72x72)

* correct folder name

* Delete offline.png

* Delete dnd.png

* Delete online.png

* Delete away.png

* make icons white

* correct size
This commit is contained in:
Michał Odziemczyk 2018-03-14 15:31:58 +01:00 committed by Harrison Healey
parent f1ea485ba0
commit 3a3be22af0
5 changed files with 12 additions and 10 deletions

View file

@ -2,17 +2,20 @@
// See License.txt for license information.
import React, {PureComponent} from 'react';
import {Image} from 'react-native';
import PropTypes from 'prop-types';
import {General} from 'mattermost-redux/constants';
import {AwayIcon, DndIcon, OfflineIcon, OnlineIcon} from 'app/components/status_icons';
import away from 'assets/images/status/away.png';
import dnd from 'assets/images/status/dnd.png';
import offline from 'assets/images/status/offline.png';
import online from 'assets/images/status/online.png';
const statusToIcon = {
away: AwayIcon,
dnd: DndIcon,
offline: OfflineIcon,
online: OnlineIcon,
away,
dnd,
offline,
online,
};
export default class UserStatus extends PureComponent {
@ -48,10 +51,9 @@ export default class UserStatus extends PureComponent {
}
return (
<Icon
height={size}
width={size}
color={iconColor}
<Image
source={Icon}
style={{height: size, width: size, tintColor: iconColor}}
/>
);
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 979 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 818 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB