Skip to content

Commit

Permalink
#156 added hover style to action buttons
Browse files Browse the repository at this point in the history
  • Loading branch information
smcgrath0 committed Sep 1, 2020
1 parent b614b41 commit 12f4b29
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 4 deletions.
2 changes: 1 addition & 1 deletion fragments/datalist/template.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<div class="selected w-full flex justify-between p-3">
<div class="selected-text">0 Selected</div>
<div class="selected-actions">
<svg class="w-24 cursor-pointer" focusable="false" viewBox="0 0 24 24" aria-hidden="true">
<svg class="w-24 cursor-pointer action-btn" focusable="false" viewBox="0 0 24 24" aria-hidden="true">
<path d="M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zM19 4h-3.5l-1-1h-5l-1 1H5v2h14V4z"></path>
</svg>
</div>
Expand Down
2 changes: 1 addition & 1 deletion fragments/datalist/template.vue
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<div class="selected-text">{{`${active.filter(element =&gt; element === true).length} selected`}}</div>
<div
class="selected-actions">
<svg class="w-24 cursor-pointer" focusable="false" viewBox="0 0 24 24"
<svg class="w-24 cursor-pointer action-btn" focusable="false" viewBox="0 0 24 24"
aria-hidden="true" v-on:click="deleteAction">
<path d="M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zM19 4h-3.5l-1-1h-5l-1 1H5v2h14V4z"
/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<div class="selected-text">{{`${active.filter(element =&gt; element === true).length} selected`}}</div>
<div
class="selected-actions">
<svg class="w-24 cursor-pointer" focusable="false" viewBox="0 0 24 24"
<svg class="w-24 cursor-pointer action-btn" focusable="false" viewBox="0 0 24 24"
aria-hidden="true" v-on:click="deleteAction">
<path d="M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zM19 4h-3.5l-1-1h-5l-1 1H5v2h14V4z"
/>
Expand Down Expand Up @@ -197,7 +197,21 @@
}
},
deleteAction: function() {
if(this.model.endpointurl && this.model.endpointurl !== '') {
// load data from URL
axios.post(this.model.endpointurl, {
firstName: 'Fred',
lastName: 'Flinstone'
})
.then( (response) => {
console.log(response)
// Vue.set(this, 'storageData', response.data)
// Vue.set(this, 'active', new Array(response.data.length).fill(false))
})
.catch( (error) => {
console.log(error)
})
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -249,4 +249,7 @@
#peregrine-app [class$="-components-datalist"].theme-dark table.striped tbody tr:nth-of-type(2n) td:not(.mobile-header) *{
color: var(--text-secondary-color);
fill: var(--text-secondary-color);
}
#peregrine-app [class$="-components-datalist"] .action-btn:hover {
fill: var(--text-secondary-color);
}

0 comments on commit 12f4b29

Please sign in to comment.