mirror of
https://github.com/go-vikunja/vikunja.git
synced 2026-02-01 22:47:40 +00:00
fix: implement review feedback on ListLabels and ShowTasks
- Move edit button to replace delete button in ListLabels - Remove separate delete button (edit button now uses delete icon styling) - Remove Icon import and unused styles from ListLabels - Add tooltip to clear label filter button - Add translation key for clear filter tooltip - Remove bold font-weight from filter label text Co-authored-by: kolaente <13721712+kolaente@users.noreply.github.com>
This commit is contained in:
@@ -808,7 +808,8 @@
|
||||
"fromuntil": "Tasks from {from} until {until}",
|
||||
"select": "Select a date range",
|
||||
"noTasks": "Nothing to do — Have a nice day!",
|
||||
"filterByLabel": "Filtering by label {label}"
|
||||
"filterByLabel": "Filtering by label {label}",
|
||||
"clearLabelFilter": "Clear label filter"
|
||||
},
|
||||
"detail": {
|
||||
"chooseDueDate": "Click here to set a due date",
|
||||
|
||||
@@ -39,18 +39,10 @@
|
||||
:label="label"
|
||||
:clickable="true"
|
||||
/>
|
||||
<BaseButton
|
||||
v-if="userInfo.id === label.createdBy.id"
|
||||
class="edit-button"
|
||||
:style="{'color': label.textColor}"
|
||||
@click="editLabel(label)"
|
||||
>
|
||||
<Icon icon="pen" />
|
||||
</BaseButton>
|
||||
<BaseButton
|
||||
v-if="userInfo.id === label.createdBy.id"
|
||||
class="delete is-small"
|
||||
@click="showDeleteDialoge(label)"
|
||||
@click="editLabel(label)"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
@@ -141,7 +133,6 @@ import BaseButton from '@/components/base/BaseButton.vue'
|
||||
import Editor from '@/components/input/AsyncEditor'
|
||||
import ColorPicker from '@/components/input/ColorPicker.vue'
|
||||
import XLabel from '@/components/tasks/partials/Label.vue'
|
||||
import Icon from '@/components/misc/Icon'
|
||||
|
||||
import LabelModel from '@/models/label'
|
||||
import type {ILabel} from '@/modelTypes/ILabel'
|
||||
@@ -149,7 +140,6 @@ import {useAuthStore} from '@/stores/auth'
|
||||
import {useLabelStore} from '@/stores/labels'
|
||||
|
||||
import { useTitle } from '@/composables/useTitle'
|
||||
import {useLabelStyles} from '@/composables/useLabelStyles'
|
||||
|
||||
const {t} = useI18n({useScope: 'global'})
|
||||
|
||||
@@ -168,7 +158,6 @@ const labelStore = useLabelStore()
|
||||
labelStore.loadAllLabels()
|
||||
|
||||
const loading = computed(() => labelStore.isLoading)
|
||||
const {getLabelStyles} = useLabelStyles()
|
||||
|
||||
function deleteLabel(label?: ILabel) {
|
||||
if (!label) {
|
||||
@@ -223,16 +212,5 @@ function showDeleteDialoge(label: ILabel) {
|
||||
&.disabled {
|
||||
opacity: 0.6;
|
||||
}
|
||||
|
||||
.edit-button {
|
||||
padding: 0.25rem 0.5rem;
|
||||
background: transparent;
|
||||
border: none;
|
||||
cursor: pointer;
|
||||
|
||||
&:hover {
|
||||
opacity: 0.8;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -24,6 +24,7 @@
|
||||
</template>
|
||||
</i18n-t>
|
||||
<BaseButton
|
||||
v-tooltip="$t('task.show.clearLabelFilter')"
|
||||
class="clear-filter-button"
|
||||
@click="clearLabelFilter"
|
||||
>
|
||||
@@ -307,7 +308,6 @@ watchEffect(() => setTitle(pageTitle.value))
|
||||
border-radius: $radius;
|
||||
|
||||
.filter-label-text {
|
||||
font-weight: 600;
|
||||
color: var(--grey-700);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user