-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(limel-list): add checkbox to list item
- Loading branch information
1 parent
5b4759a
commit 5cfe177
Showing
8 changed files
with
214 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
@import "@lime-material/list/mdc-list"; | ||
@import '@lime-material/checkbox/mdc-checkbox'; | ||
|
||
:host { | ||
display: block; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
import { Component } from '@stencil/core'; | ||
import { ListItem } from '../../interface'; | ||
|
||
@Component({ | ||
tag: 'limel-example-list-checkboxes', | ||
shadow: true, | ||
}) | ||
export class ListCheckboxesExample { | ||
private items: ListItem[] = [ | ||
{ text: 'King of Tokyo', id: 1 }, | ||
{ text: 'Smash Up!', id: 2, checked: true }, | ||
{ text: 'Pandemic', id: 3 }, | ||
{ text: 'Catan', id: 4 }, | ||
{ text: 'Ticket to Ride', id: 5 }, | ||
]; | ||
|
||
public render() { | ||
return [ | ||
<limel-list | ||
onChange={event => { | ||
console.log(event.detail); | ||
}} | ||
includeCheckboxes={true} | ||
items={this.items} | ||
/>, | ||
<hr />, | ||
<p> | ||
When importing ListItem, see{' '} | ||
<a href="/usage#import-statements">Usage</a> | ||
</p>, | ||
]; | ||
} | ||
} |