mirror of
				https://github.com/Unleash/unleash.git
				synced 2025-10-27 11:02:16 +01:00 
			
		
		
		
	fix getIcon
This commit is contained in:
		
							parent
							
								
									659b668814
								
							
						
					
					
						commit
						f462da5224
					
				@ -1,7 +1,6 @@
 | 
			
		||||
const React = require('react');
 | 
			
		||||
const {
 | 
			
		||||
    List, ListItem, ListItemContent,
 | 
			
		||||
    Grid, Cell,
 | 
			
		||||
    Button, Icon,
 | 
			
		||||
    Switch,
 | 
			
		||||
} = require('react-mdl');
 | 
			
		||||
@ -70,3 +69,13 @@ export const TogglesLinkList = ({ toggles }) => (
 | 
			
		||||
    ))}
 | 
			
		||||
    </List>
 | 
			
		||||
);
 | 
			
		||||
 | 
			
		||||
export function getIcon (type) {
 | 
			
		||||
    switch (type) {
 | 
			
		||||
        case 'feature-updated': return 'autorenew';
 | 
			
		||||
        case 'feature-created': return 'add';
 | 
			
		||||
        case 'feature-deleted': return 'remove';
 | 
			
		||||
        case 'feature-archived': return 'archived';
 | 
			
		||||
        default: return 'star';
 | 
			
		||||
    }
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
@ -10,9 +10,8 @@ import EditFeatureToggle from './form-edit-container.jsx';
 | 
			
		||||
import { fetchFeatureToggles, toggleFeature } from '../../store/feature-actions';
 | 
			
		||||
import { fetchFeatureMetrics, fetchSeenApps } from '../../store/feature-metrics-actions';
 | 
			
		||||
import { fetchHistoryForToggle } from '../../store/history-actions';
 | 
			
		||||
import { getIcon } from '../history/history-item-diff';
 | 
			
		||||
 | 
			
		||||
import { AppsLinkList, SwitchWithLabel } from '../common';
 | 
			
		||||
import { AppsLinkList, SwitchWithLabel, getIcon } from '../common';
 | 
			
		||||
 | 
			
		||||
class EditFeatureToggleWrapper extends React.Component {
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user