Web:Components:Selector: fix types after merge master
This commit is contained in:
parent
92a42b6c9c
commit
8e77c379f6
@ -17,6 +17,7 @@ export type SelectorProps = {
|
||||
id?: string;
|
||||
className?: string;
|
||||
style?: React.CSSProperties;
|
||||
withHeader?: boolean;
|
||||
headerLabel: string;
|
||||
withoutBackButton?: boolean;
|
||||
onBackClick?: () => void;
|
||||
|
@ -67,11 +67,8 @@ const Selector = ({
|
||||
loadNextPage,
|
||||
totalItems,
|
||||
isLoading,
|
||||
searchLoader,
|
||||
rowLoader,
|
||||
|
||||
withHeader,
|
||||
}) => {
|
||||
const [footerVisible, setFooterVisible] = React.useState(false);
|
||||
|
||||
withFooterInput,
|
||||
withFooterCheckbox,
|
||||
@ -394,8 +391,8 @@ const Selector = ({
|
||||
// /** Accepts css style */
|
||||
// style: PropTypes.object,
|
||||
|
||||
/** Add header */
|
||||
withHeader: PropTypes.bool,
|
||||
/** Add header */
|
||||
// withHeader: PropTypes.bool,
|
||||
// /** Selector header text */
|
||||
// headerLabel: PropTypes.string,
|
||||
// /** Hide header back button */
|
||||
|
@ -3,6 +3,7 @@ import { Item } from "./../Item/Item.types";
|
||||
|
||||
export type BodyProps = {
|
||||
footerVisible: boolean;
|
||||
withHeader?: boolean;
|
||||
isSearch: boolean;
|
||||
isAllIndeterminate?: boolean;
|
||||
isAllChecked?: boolean;
|
||||
|
@ -4,6 +4,7 @@ import Base from "../../../themes/base";
|
||||
|
||||
const StyledBody = styled.div<{
|
||||
footerVisible: boolean;
|
||||
withHeader?: boolean;
|
||||
footerHeight: number;
|
||||
headerHeight: number;
|
||||
}>`
|
||||
@ -11,8 +12,12 @@ const StyledBody = styled.div<{
|
||||
|
||||
height: ${(props) =>
|
||||
props.footerVisible
|
||||
? `calc(100% - 16px - ${props.footerHeight}px - ${props.headerHeight}px)`
|
||||
: `calc(100% - 16px - ${props.headerHeight}px)`};
|
||||
? props.withHeader
|
||||
? `calc(100% - 16px - ${props.footerHeight}px - ${props.headerHeight}px)`
|
||||
: `calc(100% - 16px - ${props.footerHeight}px)`
|
||||
: props.withHeader
|
||||
? `calc(100% - 16px - ${props.headerHeight}px)`
|
||||
: `calc(100% - 16px)`};
|
||||
|
||||
padding: 16px 0 0 0;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user