Skip to content

Commit

Permalink
Fixes liferay#1285 - Update demos
Browse files Browse the repository at this point in the history
  • Loading branch information
matuzalemsteles committed Dec 4, 2018
1 parent 25ba1ef commit c5d54d5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 10 deletions.
2 changes: 2 additions & 0 deletions packages/clay-multi-select/demos/a11y.html
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ <h2>With only data remote</h2>
itemRemoved: removeItem,
itemSelected: (event) => {
const label = event.data.originalString.toLowerCase();
if (event.target.selectedItems.find(item => item.value === label)) return;
event.target.selectedItems.push({label, value: label});
addToSelectedItems(event);
},
Expand All @@ -133,6 +134,7 @@ <h2>With only data remote</h2>
itemRemoved: removeItem,
itemSelected: (event) => {
const label = event.data.originalString.toLowerCase();
if (event.target.selectedItems.find(item => item.value === label)) return;
event.target.selectedItems.push({label, value: label});
addToSelectedItems(event);
},
Expand Down
12 changes: 2 additions & 10 deletions packages/clay-multi-select/demos/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,6 @@
.row {
margin-bottom: 20px;
}

.label-focus {
background-color: #0B5FFF;
border-color: #0B5FFF;
color: #FFF;
}

.dropdown-full {
position: relative;
}
</style>

<script src="../build/globals/clay-multi-select.js"></script>
Expand Down Expand Up @@ -129,6 +119,7 @@ <h2>With only data remote</h2>
itemRemoved: removeItem,
itemSelected: (event) => {
const label = event.data.originalString.toLowerCase();
if (event.target.selectedItems.find(item => item.value === label)) return;
event.target.selectedItems.push({label, value: label});
addToSelectedItems(event);
},
Expand All @@ -143,6 +134,7 @@ <h2>With only data remote</h2>
itemRemoved: removeItem,
itemSelected: (event) => {
const label = event.data.originalString.toLowerCase();
if (event.target.selectedItems.find(item => item.value === label)) return;
event.target.selectedItems.push({label, value: label});
addToSelectedItems(event);
},
Expand Down

0 comments on commit c5d54d5

Please sign in to comment.