mirror of
https://github.com/oxen-io/session-desktop.git
synced 2023-12-14 02:12:57 +01:00
fix compile errors with SessionIcon
This commit is contained in:
parent
5edfa530f2
commit
70e72cb92d
2 changed files with 6 additions and 4 deletions
|
@ -1,7 +1,7 @@
|
|||
import React from 'react';
|
||||
|
||||
import { icons, SessionIconSize, SessionIconType } from '../icon';
|
||||
import styled, { css, DefaultTheme, keyframes } from 'styled-components';
|
||||
import _ from 'lodash';
|
||||
|
||||
export type SessionIconProps = {
|
||||
iconType: SessionIconType;
|
||||
|
@ -51,7 +51,7 @@ const rotate = keyframes`
|
|||
}
|
||||
`;
|
||||
|
||||
const animation = (props: any) => {
|
||||
const animation = (props: { rotateDuration?: any }) => {
|
||||
if (props.rotateDuration) {
|
||||
return css`
|
||||
${rotate} ${props.rotateDuration}s infinite linear;
|
||||
|
@ -81,9 +81,10 @@ const SessionSvg = (props: {
|
|||
}) => {
|
||||
const colorSvg = props.iconColor || props?.theme?.colors.textColor;
|
||||
const pathArray = props.path instanceof Array ? props.path : [props.path];
|
||||
const propsToPick = _.pick(props, 'width', 'animation', 'transform') as any;
|
||||
|
||||
return (
|
||||
<Svg {...props}>
|
||||
<Svg {...propsToPick}>
|
||||
{pathArray.map((path, index) => {
|
||||
return <path key={index} fill={colorSvg} d={path} />;
|
||||
})}
|
||||
|
|
3
ts/window.d.ts
vendored
3
ts/window.d.ts
vendored
|
@ -1,3 +1,5 @@
|
|||
import {} from 'styled-components/cssprop';
|
||||
|
||||
import { LocalizerType } from '../types/Util';
|
||||
import { LibsignalProtocol } from '../../libtextsecure/libsignal-protocol';
|
||||
import { SignalInterface } from '../../js/modules/signal';
|
||||
|
@ -5,7 +7,6 @@ import { Libloki } from '../libloki';
|
|||
|
||||
import { LibTextsecure } from '../libtextsecure';
|
||||
import { ConfirmationDialogParams } from '../background';
|
||||
import {} from 'styled-components/cssprop';
|
||||
|
||||
import { ConversationControllerType } from '../js/ConversationController';
|
||||
import { any } from 'underscore';
|
||||
|
|
Loading…
Reference in a new issue