I use footnotes for citations in combination with the beamer
package. I adapted the code from this question and everything works quice nicely - except when using overlays. Then the footnotes only show on one slide but are hidden afterwards as shown below.
So my question is: How can I accomplish that the footnotes appear on the same slide as the corresponding item? If that is not possible, the footnotes should at least be visible until the next frame appears.
Here is my MWE:
\documentclass{beamer}
\usepackage[english]{babel}
\usepackage{csquotes}
\usepackage[style=numeric-comp, backend=biber, citetracker=true,sorting=none]{biblatex}
\usepackage{hyperref}
\addbibresource{biblatex-examples.bib}
\makeatletter
\newtoggle{cbx@togcite}
% Citation number in brackets
\renewcommand\@makefntext[1]{%
\iftoggle{cbx@togcite}
{{\normalfont[\@thefnmark]}\enspace #1}
{{\normalfont\@thefnmark}\enspace #1}%
\global\togglefalse{cbx@togcite}}
\DeclareCiteCommand{\sfcite}[\cbx@superscript]%
{\usebibmacro{cite:init}%
\let\multicitedelim=\supercitedelim
\iffieldundef{prenote}
{}
{\BibliographyWarning{Ignoring prenote argument}}%
\iffieldundef{postnote}
{}
{\BibliographyWarning{Ignoring postnote argument}}}
{\usebibmacro{citeindex}%
\usebibmacro{sfcite}%
\usebibmacro{cite:comp}}
{}
{\usebibmacro{cite:dump}}
\newbibmacro*{sfcite}{%
\ifciteseen
{}
{\xappto\cbx@citehook{%
\global\toggletrue{cbx@togcite}%
\noexpand\footnotetext[\thefield{labelnumber}]{%
\fullcite{\thefield{entrykey}}\addperiod}}}}
\newrobustcmd{\cbx@superscript}[1]{%
\mkbibsuperscript{\mkbibbrackets{#1}}%
\cbx@citehook%
\global\let\cbx@citehook=\empty}
\let\cbx@citehook=\empty
\makeatother
\begin{document}
\begin{frame}
\frametitle{First Frame}
\begin{itemize}[<+->]
\item First citation. \sfcite{reese}
\item Second citation.\sfcite{springer}
\end{itemize}
\end{frame}
\begin{frame}
\frametitle{Second Frame}
Third citation.\sfcite{glashow}
\end{frame}
\end{document}
\only<2>{\sfcite{springer}}
to the second\item
you get at least the footnotes on the right slide.\only<2->{\sfcite{springer}}
would be a workaround for more than 2 items.