PromucFlow_constructor/app/client/src/editorComponents/CalloutComponent.tsx

31 lines
801 B
TypeScript
Raw Normal View History

2019-03-13 15:55:53 +00:00
import * as React from "react";
import { IComponentProps } from "./BaseComponent";
import PositionContainer from "./PositionContainer";
import { Callout, Code, H5, Intent, Switch } from "@blueprintjs/core";
2019-03-13 15:55:53 +00:00
class CalloutComponent extends React.Component<ICalloutComponentProps> {
render() {
return (
<PositionContainer {...this.props}>
<Callout
{...this.props}
title={this.props.title ? this.props.title : undefined}
intent={this.props.intent}
>
2019-03-13 15:55:53 +00:00
{this.props.description}
</Callout>
</PositionContainer>
2019-03-13 15:55:53 +00:00
);
}
}
export interface ICalloutComponentProps extends IComponentProps {
id?: string;
title?: string;
2019-03-13 15:55:53 +00:00
description?: string;
intent?: Intent;
2019-03-13 15:55:53 +00:00
ellipsize?: boolean;
}
export default CalloutComponent;