mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-17 14:47:53 +01:00
Client Fixed (#9017)
* fix spacing between rewards and items * fix rewards description * rewards cost in bold * fix gp notifications * fix dailies gray text * fix cancel in task edit modal * tags: use AND not OR for filtering * fix tasksDefaults so that monthlies can be created correctly * tags: usable if no task selected, saving checklist and tags saved the one being added without requiting to press enter * remove tags from tasks when they are deleted * fix tags removal when multiple tags are deleted and fix tags editing
This commit is contained in:
@@ -18,7 +18,7 @@
|
||||
@editTask="editTask",
|
||||
:group='group',
|
||||
)
|
||||
template(v-if="isUser === true && type === 'reward' && activeFilter.label !== 'custom'")
|
||||
template(v-if="hasRewardsList")
|
||||
.reward-items
|
||||
shopItem(
|
||||
v-for="reward in inAppRewards",
|
||||
@@ -31,7 +31,7 @@
|
||||
|
||||
.column-background(
|
||||
v-if="isUser === true",
|
||||
:class="{'initial-description': tasks[`${type}s`].length === 0}",
|
||||
:class="{'initial-description': initialColumnDescription}",
|
||||
ref="columnBackground",
|
||||
)
|
||||
.svg-icon(v-html="icons[type]", :class="`icon-${type}`", v-once)
|
||||
@@ -46,7 +46,7 @@
|
||||
height: 556px;
|
||||
}
|
||||
|
||||
.task + .reward-items {
|
||||
.task-wrapper + .reward-items {
|
||||
margin-top: 16px;
|
||||
}
|
||||
|
||||
@@ -243,6 +243,17 @@ export default {
|
||||
inAppRewards () {
|
||||
return inAppRewards(this.user);
|
||||
},
|
||||
hasRewardsList () {
|
||||
return this.isUser === true && this.type === 'reward' && this.activeFilter.label !== 'custom';
|
||||
},
|
||||
initialColumnDescription () {
|
||||
// Show the column description in the middle only if there are no elements (tasks or in app items)
|
||||
if (this.hasRewardsList) {
|
||||
if (this.inAppRewards && this.inAppRewards.length >= 0) return false;
|
||||
}
|
||||
|
||||
return this.tasks[`${this.type}s`].length === 0;
|
||||
},
|
||||
},
|
||||
watch: {
|
||||
taskList: {
|
||||
@@ -299,11 +310,11 @@ export default {
|
||||
const selectedTags = this.selectedTags;
|
||||
|
||||
if (selectedTags && selectedTags.length > 0) {
|
||||
const hasSelectedTag = task.tags.find(tagId => {
|
||||
return selectedTags.indexOf(tagId) !== -1;
|
||||
const hasAllSelectedTag = selectedTags.every(tagId => {
|
||||
return task.tags.indexOf(tagId) !== -1;
|
||||
});
|
||||
|
||||
if (!hasSelectedTag) return false;
|
||||
if (!hasAllSelectedTag) return false;
|
||||
}
|
||||
|
||||
// Text
|
||||
|
||||
Reference in New Issue
Block a user