isomtrik-quickchat
Version:
isomtrik-quickchat is a lightweight, real-time chat component built with Stencil JS. It is designed to be seamlessly integrated into web applications, offering customizable and responsive chat functionalities. The module supports both CommonJS and ES modu
37 lines (30 loc) • 1.05 kB
JavaScript
import {html, LitElement } from 'lit';
class MessageDatePill extends LitElement {
static properties = {
bgColor: { type: String },
textColor: { type: String },
width: { type: String },
padding: { type: String },
borderRadius: { type: String },
borderWidth: { type: String },
borderColor: { type: String },
fontSize: { type: String },
fontWeight: { type: String },
fontFamily: { type: String },
content: { type: String },
};
render() {
return html`
<div
style="background-color: ${this.bgColor || '#F9E3FF'}; width: ${this.width};
border-radius: ${this.borderRadius}; border-width: ${this.borderWidth}; border-color: ${this.borderColor};
padding: ${this.padding}; color: ${this.textColor}; font-family: ${this.fontFamily};
font-size: ${this.fontSize}; font-weight: ${this.fontWeight};
"
>
${this.content}
</div>
`;
}
}
customElements.define('message-date-pill', MessageDatePill);