@salla.sa/twilight-components
Version:
Salla Web Component
37 lines (33 loc) • 2.32 kB
JavaScript
/*!
* Crafted with ❤ by Salla
*/
import { proxyCustomElement, HTMLElement, h } from '@stencil/core/internal/client';
const sallaNotificationsCss = "";
const SallaNotificationItem = /*@__PURE__*/ proxyCustomElement(class SallaNotificationItem extends HTMLElement {
constructor() {
super();
this.__registerHost();
}
render() {
return h("a", { key: '1b234e649b23636170f30dfc46884e047d0f02ce', href: this.notification.url, class: { "s-notifications-item": true, "s-notifications-item-shadow": true, "s-notifications-item-read": !this.notification.is_new } }, h("span", { key: '948c47868767a413bc488287af46caac7aa35c1e', class: "s-notifications-item-icon" }, h("i", { key: '2ac3ada00bd7d7f3a6d5ba85341628ac382acef5', class: { 's-notifications-item-icon sicon-bell-ring': true, 's-notifications-item-icon-new': this.notification.is_new } })), h("div", { key: 'a19c06341302bc389a2f5829c06367c03372fbfb', class: "s-notifications-item-content" }, h("div", { key: '77ed75864e91b39095ee2505e10f432fbc896ec5', class: "s-notifications-item-content-leading" }, h("h4", { key: 'cee7566266dff68eeb2d8635e1eeaf2745b1930f' }, this.notification.title), h("p", { key: '459ffde17436ff4311c64ee7f53966283390c410' }, this.notification.sub_title)), h("span", { key: 'b681d2c40f719e7d6d1e5abda8993b1bb870cbb6', class: "s-notifications-item-content-trailing" }, h("i", { key: '2cd02287aaeeeaa00f972f4e0448f66e96949525', class: "sicon-time s-notifications-item-content-trailing-icon" }), h("span", { key: '4fd57d3f80816b0e607d5e6900d7975f94cf0892' }, this.notification.date))));
}
static get style() { return sallaNotificationsCss; }
}, [0, "salla-notification-item", {
"notification": [16]
}]);
function defineCustomElement() {
if (typeof customElements === "undefined") {
return;
}
const components = ["salla-notification-item"];
components.forEach(tagName => { switch (tagName) {
case "salla-notification-item":
if (!customElements.get(tagName)) {
customElements.define(tagName, SallaNotificationItem);
}
break;
} });
}
export { SallaNotificationItem as S, defineCustomElement as d };
//# sourceMappingURL=salla-notification-item2.js.map
//# sourceMappingURL=salla-notification-item2.js.map