mirror of
https://github.com/LemmyNet/lemmy-ui.git
synced 2024-11-01 18:19:55 +00:00
b64f47cfe9
* Removing monads. Fixes #884 * Fixing post fetching. * Dont show not_logged_in error for navbar. * Adding the lemmy-js-client RC. * Fixing registration application mode
31 lines
712 B
TypeScript
31 lines
712 B
TypeScript
import { Component } from "inferno";
|
|
import { PictrsImage } from "./pictrs-image";
|
|
|
|
interface BannerIconHeaderProps {
|
|
banner?: string;
|
|
icon?: string;
|
|
}
|
|
|
|
export class BannerIconHeader extends Component<BannerIconHeaderProps, any> {
|
|
constructor(props: any, context: any) {
|
|
super(props, context);
|
|
}
|
|
|
|
render() {
|
|
let banner = this.props.banner;
|
|
let icon = this.props.icon;
|
|
return (
|
|
<div className="position-relative mb-2">
|
|
{banner && <PictrsImage src={banner} banner alt="" />}
|
|
{icon && (
|
|
<PictrsImage
|
|
src={icon}
|
|
iconOverlay
|
|
pushup={!!this.props.banner}
|
|
alt=""
|
|
/>
|
|
)}
|
|
</div>
|
|
);
|
|
}
|
|
}
|