mirror of
https://gitlab.ub.uni-bielefeld.de/sfb1288inf/nopaque.git
synced 2024-12-25 02:44:18 +00:00
Change logic for colorization of followed corpora in corpus Lists
This commit is contained in:
parent
47b9a90cb6
commit
c3306563f0
@ -20,18 +20,20 @@ class CorpusList extends ResourceList {
|
|||||||
|
|
||||||
// #region Mandatory getters and methods to implement
|
// #region Mandatory getters and methods to implement
|
||||||
get item() {
|
get item() {
|
||||||
return `
|
return (values) => {
|
||||||
<tr class="list-item clickable hoverable">
|
return `
|
||||||
<td><a class="btn-floating disabled"><i class="material-icons service-color darken" data-service="corpus-analysis">book</i></a></td>
|
<tr class="${values['is-owner'] ? '' : 'deep-purple lighten-5'} list-item clickable hoverable">
|
||||||
<td><b class="title"></b><br><i class="description"></i></td>
|
<td><a class="btn-floating disabled"><i class="material-icons service-color darken" data-service="corpus-analysis">book</i></a></td>
|
||||||
<td><span class="owner"></span></td>
|
<td><b class="title"></b><br><i class="description"></i></td>
|
||||||
<td><span class="status badge new corpus-status-color corpus-status-text" data-badge-caption=""></span></td>
|
<td><span class="owner"></span></td>
|
||||||
<td class="right-align">
|
<td><span class="status badge new corpus-status-color corpus-status-text" data-badge-caption=""></span></td>
|
||||||
<a class="list-action-trigger btn-floating red waves-effect waves-light" data-list-action="delete-request"><i class="material-icons">delete</i></a>
|
<td class="right-align">
|
||||||
<a class="list-action-trigger btn-floating service-color darken waves-effect waves-light" data-list-action="view" data-service="corpus-analysis"><i class="material-icons">send</i></a>
|
<a class="list-action-trigger btn-floating red waves-effect waves-light" data-list-action="delete-request"><i class="material-icons">delete</i></a>
|
||||||
</td>
|
<a class="list-action-trigger btn-floating service-color darken waves-effect waves-light" data-list-action="view" data-service="corpus-analysis"><i class="material-icons">send</i></a>
|
||||||
</tr>
|
</td>
|
||||||
`.trim();
|
</tr>
|
||||||
|
`.trim();
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
get valueNames() {
|
get valueNames() {
|
||||||
@ -42,7 +44,6 @@ class CorpusList extends ResourceList {
|
|||||||
'description',
|
'description',
|
||||||
'title',
|
'title',
|
||||||
'owner',
|
'owner',
|
||||||
{data: ['is-owner']}
|
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -147,9 +147,5 @@
|
|||||||
{% endfor %}
|
{% endfor %}
|
||||||
]
|
]
|
||||||
);
|
);
|
||||||
corpusItems = document.querySelectorAll('[data-is-owner="false"]');
|
|
||||||
corpusItems.forEach((item) => {
|
|
||||||
item.classList.add('deep-purple', 'lighten-5');
|
|
||||||
});
|
|
||||||
</script>
|
</script>
|
||||||
{% endblock scripts %}
|
{% endblock scripts %}
|
||||||
|
Loading…
Reference in New Issue
Block a user