igniteui-webcomponents
Version:
Ignite UI for Web Components is a complete library of UI components, giving you the ability to build modern web applications using encapsulation and the concept of reusable components in a dependency-free approach.
53 lines • 2.15 kB
JavaScript
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
return c > 3 && r && Object.defineProperty(target, key, r), r;
};
import { html, LitElement } from 'lit';
import { property } from 'lit/decorators.js';
import { addThemingController } from '../../theming/theming-controller.js';
import { addInternalsController } from '../common/controllers/internals.js';
import { registerComponent } from '../common/definitions/register.js';
import { styles } from './themes/item.base.css.js';
import { all } from './themes/item.js';
import { styles as shared } from './themes/shared/item/list-item.common.css.js';
class IgcListItemComponent extends LitElement {
static register() {
registerComponent(IgcListItemComponent);
}
constructor() {
super();
this.selected = false;
addThemingController(this, all);
addInternalsController(this, {
initialARIA: {
role: 'listitem',
},
});
}
render() {
return html `
<section part="start">
<slot name="start"></slot>
</section>
<section part="content">
<header part="header">
<slot part="title" name="title"></slot>
<slot part="subtitle" name="subtitle"></slot>
</header>
<slot></slot>
</section>
<section part="end">
<slot name="end"></slot>
</section>
`;
}
}
IgcListItemComponent.tagName = 'igc-list-item';
IgcListItemComponent.styles = [styles, shared];
export default IgcListItemComponent;
__decorate([
property({ type: Boolean, reflect: true })
], IgcListItemComponent.prototype, "selected", void 0);
//# sourceMappingURL=list-item.js.map