如何更改引文中的年份颜色,哈佛风格(作者,年份)引文?

如何更改引文中的年份颜色,哈佛风格(作者,年份)引文?

在此处输入图片描述这是 MWE。有人能帮我解决这个问题吗?请在代码中查找详细问题。如果我必须更新一年的命令,我该如何在 .bst 或 .sty 文件中执行此操作?

\documentclass[12pt]{article}
\usepackage[main=english]{babel}
\usepackage{harvard,url,hyperref}
\hypersetup{colorlinks,linkcolor={blue},citecolor={blue},urlcolor={blue}}
\bibliographystyle{jphysicsB_withTitles.bst}
\usepackage{filecontents}
\begin{filecontents}{final.bib}
@Article{jan2004gate,
    title={{A simulation toolkit for new applications}},
    author={Jan, Slake and Santa, G and others},
    journal={New. Med. Jour.},
    volume={\href{https://iopscience.iop.org/article/10.1088/0031-9155/49/19/007/meta}{59}},
    pages={\href{https://iopscience.iop.org/article/10.1088/0031-9155/49/19/007/meta}{45400}},
    year={2004},
    publisher={IOP Publishing}
}
\end{filecontents}

\begin{document}
I want to make this citation as (Jan et al. {\textcolor{blue}{2004}}) not as 
\cite{jan2004gate}. When I change the color of year inside the bibtex then the color of year will be blue, however this also changes the year color blue in references list, which I do not want to have. 

So, how to change the color of year in the cited text as (Jan et al. {\textcolor{blue}{2004}}) without changing its color as shown in following reference list?

Do I need to change anything in .bst/.sty file? Or, simply renew the command using latex renewcommand?

\bibliography{final}
\end{document}

相关内容