From 3bf12a98a7062f02edb1cd3f4e1209ac34dc55ec Mon Sep 17 00:00:00 2001 From: fragosti Date: Fri, 20 Jul 2018 09:55:08 -0700 Subject: Implement tooltips --- packages/website/ts/components/ui/allowance_state_view.tsx | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'packages/website/ts/components/ui') diff --git a/packages/website/ts/components/ui/allowance_state_view.tsx b/packages/website/ts/components/ui/allowance_state_view.tsx index fce06c664..eecf88c34 100644 --- a/packages/website/ts/components/ui/allowance_state_view.tsx +++ b/packages/website/ts/components/ui/allowance_state_view.tsx @@ -3,7 +3,11 @@ import CircularProgress from 'material-ui/CircularProgress'; import * as React from 'react'; import { styled } from 'ts/style/theme'; -export type AllowanceState = 'locked' | 'unlocked' | 'loading'; +export enum AllowanceState { + Locked, + Unlocked, + Loading, +} export interface AllowanceStateViewProps { allowanceState: AllowanceState; @@ -11,11 +15,11 @@ export interface AllowanceStateViewProps { export const AllowanceStateView: React.StatelessComponent = ({ allowanceState }) => { switch (allowanceState) { - case 'locked': + case AllowanceState.Locked: return renderLock(); - case 'unlocked': + case AllowanceState.Unlocked: return renderCheck(); - case 'loading': + case AllowanceState.Loading: return ; default: return null; -- cgit