From a0e3237de6e2441be0e0a79bdfe1b5a2caf3e4d6 Mon Sep 17 00:00:00 2001 From: Shariq Ansari Date: Tue, 1 Aug 2023 18:17:41 +0530 Subject: [PATCH] fix: dynamic status icon color in dropdown --- frontend/src/pages/Lead.vue | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/frontend/src/pages/Lead.vue b/frontend/src/pages/Lead.vue index d16779a8..923f8ccc 100644 --- a/frontend/src/pages/Lead.vue +++ b/frontend/src/pages/Lead.vue @@ -122,7 +122,7 @@ import { } from 'frappe-ui' import { TransitionPresets, useTransition } from '@vueuse/core' import { usersStore } from '@/stores/users' -import { ref, computed } from 'vue' +import { ref, computed, h } from 'vue' import Breadcrumbs from '@/components/Breadcrumbs.vue' const { getUser } = usersStore() @@ -220,35 +220,35 @@ function onTabChange(index) { const statusDropdownOptions = [ { label: 'New', - icon: IndicatorIcon, + icon: () => h(IndicatorIcon, { class: '!text-gray-600' }), onClick: () => { lead.doc.status = 'New' }, }, { label: 'Contact made', - icon: IndicatorIcon, + icon: () => h(IndicatorIcon, { class: 'text-orange-600' }), onClick: () => { lead.doc.status = 'Contact made' }, }, { label: 'Proposal made', - icon: IndicatorIcon, + icon: () => h(IndicatorIcon, { class: '!text-blue-600' }), onClick: () => { lead.doc.status = 'Proposal made' }, }, { label: 'Negotiation', - icon: IndicatorIcon, + icon: () => h(IndicatorIcon, { class: 'text-red-600' }), onClick: () => { lead.doc.status = 'Negotiation' }, }, { label: 'Converted', - icon: IndicatorIcon, + icon: () => h(IndicatorIcon, { class: 'text-green-600' }), onClick: () => { lead.doc.status = 'Converted' },