Variables
Const SortableDragHandle
SortableDragHandle: ComponentClass<Object, any> = SortableHandle(() => <DragHandleIcon/>)
Const SortableEmbedProviderItem
Sortable
EmbedProviderItem: ComponentClass<EmbedProviderItemProps & SortableElementProps, any> = SortableElement(({providerID, onRemove}: EmbedProviderItemProps) => {let name = providerID;let iconElement;const provider = getEmbedProviderFromID(providerID);if (provider) {name = provider.name;iconElement = (<ListItemAvatar><Avatar src={provider.icon}/></ListItemAvatar>);}return (<ListItem><ListItemIcon><SortableDragHandle/></ListItemIcon>{iconElement}<ListItemText primary={name}/><ListItemSecondaryAction><IconButton onClick={onRemove}><DeleteIcon/></IconButton></ListItemSecondaryAction></ListItem>);})
Const SortableEmbedProviderList
Sortable
EmbedProviderList: ComponentClass<SortableEmbedProviderListProps & SortableContainerProps, any> = SortableContainer(({providerIDs, onRemove}: SortableEmbedProviderListProps) => {const contents = providerIDs.map((providerID, index) => {function handleDeleteClick() {if (onRemove) onRemove(index);}return (<SortableEmbedProviderItem key={index} index={index} providerID={providerID} onRemove={handleDeleteClick}/>);});return (<List>{contents}</List>);})
Const providerSuggestions
providerSuggestions: object[] = embedProviders.map(provider => ({label: provider.name,value: provider.id,}))
Const useEmbedProviderStyles
useEmbedProviderStyles: function = makeStyles((theme: Theme) => ({container: {marginBottom: theme.spacing(1),padding: theme.spacing(2, 0),},}))
Type declaration
-
- (props?: any): ClassNameMap<ClassKeyOfStyles<S>>
-
Parameters
Returns ClassNameMap<ClassKeyOfStyles<S>>
SettingsTabContent used by SettingsTab.
Settings - React component which manages all tabs.