mirror of
https://github.com/lidarr/lidarr.git
synced 2025-07-08 05:51:47 -07:00
New: Custom Filtering for UI (#234)
This commit is contained in:
parent
c6873014c7
commit
7354e02bff
154 changed files with 3498 additions and 1370 deletions
|
@ -13,4 +13,8 @@
|
|||
background-color: inherit;
|
||||
color: $iconButtonHoverColor;
|
||||
}
|
||||
|
||||
&.isDisabled {
|
||||
color: $iconButtonDisabledColor;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
import PropTypes from 'prop-types';
|
||||
import React from 'react';
|
||||
import classNames from 'classnames';
|
||||
import Icon from 'Components/Icon';
|
||||
import Link from './Link';
|
||||
import styles from './IconButton.css';
|
||||
|
@ -12,12 +13,18 @@ function IconButton(props) {
|
|||
kind,
|
||||
size,
|
||||
isSpinning,
|
||||
isDisabled,
|
||||
...otherProps
|
||||
} = props;
|
||||
|
||||
return (
|
||||
<Link
|
||||
className={className}
|
||||
className={classNames(
|
||||
className,
|
||||
isDisabled && styles.isDisabled
|
||||
)}
|
||||
isDisabled={isDisabled}
|
||||
|
||||
{...otherProps}
|
||||
>
|
||||
<Icon
|
||||
|
@ -37,7 +44,8 @@ IconButton.propTypes = {
|
|||
kind: PropTypes.string,
|
||||
name: PropTypes.object.isRequired,
|
||||
size: PropTypes.number,
|
||||
isSpinning: PropTypes.bool
|
||||
isSpinning: PropTypes.bool,
|
||||
isDisabled: PropTypes.bool
|
||||
};
|
||||
|
||||
IconButton.defaultProps = {
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
cursor: pointer;
|
||||
|
||||
&:global(.isDisabled) {
|
||||
pointer-events: none;
|
||||
cursor: default;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue