Skip to content

Commit

Permalink
add support for non-icon List ItemMeta prateekbh#1337
Browse files Browse the repository at this point in the history
  • Loading branch information
fopina committed Oct 8, 2019
1 parent 762edeb commit beaff72
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions packages/list/src/item/meta.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import {h} from 'preact';
import {MaterialComponent} from '@preact-material-components/base/lib/MaterialComponent';
import {
IListItemGraphicProps,
IListItemGraphicState,
Expand All @@ -12,3 +13,22 @@ export interface IListItemMetaState extends IListItemGraphicState {}
export class ListItemMeta extends ListItemGraphic {
protected componentName = 'list-item__meta';
}

export interface IListItemMetaTextProps {}
export interface IListItemMetaTextState {}

export class ListItemMetaText extends MaterialComponent<
IListItemMetaTextProps,
IListItemMetaTextState
> {
protected componentName = 'list-item__meta';
protected mdcProps = [];

protected materialDom(props) {
return (
<span {...props} ref={this.setControlRef} role="presentation">
{props.children}
</span>
);
}
}

0 comments on commit beaff72

Please sign in to comment.