Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
);
}
return React.cloneElement(title, { className, record, ...rest });
};
Title.propTypes = {
defaultTitle: PropTypes.string.isRequired,
className: PropTypes.string,
locale: PropTypes.string,
record: PropTypes.object,
translate: PropTypes.func.isRequired,
title: PropTypes.oneOfType([PropTypes.string, PropTypes.element]),
};
export default translate(Title);
FormTab.propTypes = {
className: PropTypes.string,
children: PropTypes.node,
context: PropTypes.oneOf(['header', 'content']),
hidden: PropTypes.bool,
icon: PropTypes.element,
label: PropTypes.string.isRequired,
path: PropTypes.string,
translate: PropTypes.func.isRequired,
value: PropTypes.string,
};
FormTab.displayName = 'FormTab';
export default translate(FormTab);
FormTab.propTypes = {
className: PropTypes.string,
contentClassName: PropTypes.string,
children: PropTypes.node,
intent: PropTypes.oneOf(['header', 'content']),
hidden: PropTypes.bool,
icon: PropTypes.element,
label: PropTypes.string.isRequired,
path: PropTypes.string,
translate: PropTypes.func.isRequired,
value: PropTypes.string,
};
FormTab.displayName = 'FormTab';
export default translate(FormTab);
) : (
React.cloneElement(title, { className, record, ...rest })
);
return ReactDOM.createPortal(titleElement, container);
};
Title.propTypes = {
defaultTitle: PropTypes.string,
className: PropTypes.string,
locale: PropTypes.string,
record: PropTypes.object,
translate: PropTypes.func.isRequired,
title: PropTypes.oneOfType([PropTypes.string, PropTypes.element]),
};
export default translate(Title);
to="/"
primaryText={translate('ra.page.dashboard')}
leftIcon={}
exact
{...props}
/>
);
DashboardMenuItem.propTypes = {
className: PropTypes.string,
locale: PropTypes.string,
onClick: PropTypes.func,
translate: PropTypes.func.isRequired,
};
export default translate(DashboardMenuItem);
);
}
return React.cloneElement(title, { className, record, ...rest });
};
Title.propTypes = {
defaultTitle: PropTypes.string.isRequired,
className: PropTypes.string,
locale: PropTypes.string,
record: PropTypes.object,
translate: PropTypes.func.isRequired,
title: PropTypes.oneOfType([PropTypes.string, PropTypes.element]),
};
export default translate(Title);
resource={resource}
record={emptyRecord}
/>
<div> </div>
);
FilterFormInput.propTypes = {
filterElement: PropTypes.node,
handleHide: PropTypes.func,
resource: PropTypes.string,
locale: PropTypes.string,
translate: PropTypes.func,
};
export default translate(FilterFormInput);
: this.renderContent({ children, ...rest });
}
}
Tab.propTypes = {
className: PropTypes.string,
contentClassName: PropTypes.string,
children: PropTypes.node,
context: PropTypes.oneOf(['header', 'content']),
icon: ComponentPropType,
label: PropTypes.string.isRequired,
translate: PropTypes.func.isRequired,
value: PropTypes.string,
};
export default translate(Tab);
? this.renderHeader(rest)
: this.renderContent({ children, ...rest });
}
}
Tab.propTypes = {
className: PropTypes.string,
children: PropTypes.node,
context: PropTypes.oneOf(['header', 'content']),
icon: PropTypes.element,
label: PropTypes.string.isRequired,
translate: PropTypes.func.isRequired,
value: PropTypes.string,
};
export default translate(Tab);
}}
open={open}
onClose={this.handleClose}
>
{Children.map(children, menuItem =>
isValidElement(menuItem) ?
cloneElement(menuItem, { onClick: this.handleClose }) : null
)}
{logout}
);
}
}
export default translate(UserMenu);