# How do I put the remarks and footers of a long table made with the tabularray package on all pages?

I am making a long table using longtblr from the tabularray package. This table has some notes and footers, which appear on the last page where the table is.

I want to know if there is any way to put at the bottom of the table, on every page it is on, all the remarks (remark={text}) and the footers (note={text}), keeping the text "Continued on next page".

\documentclass[12pt,a4paper]{book}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{tabularray}
\usepackage{blindtext}
\begin{document}

\begin{longtblr}[
caption={Caption},
label={tab:label},
remark{Note}={I want this note on every page where the longtblr is}
]{%
hlines,
vlines,
colspec={X[l,m]}
}

\blindtext \\
\blindtext \\
\blindtext \\
\blindtext \\
\blindtext \\
\blindtext \\
\blindtext \\
\blindtext \\
\end{longtblr}

\end{document}


# Last page

• If you have multiline notes or remarks, have a look at the new solution I posted.
– marv
Jan 21 at 11:04

You may define a new theme with the note in the continuation text in the foot by defining a new template for the continuation text.

\documentclass[12pt,a4paper]{book}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{tabularray}
\usepackage{blindtext}

\NewTblrTheme{MyTheme}{
\DefTblrTemplate{contfoot-text}{MyTmp}{%
\raggedright\UseTblrTemplate{remark}{default}
Continued on next page
}
\SetTblrTemplate{contfoot-text}{MyTmp}
}
%---------------------------------------------------------

\begin{document}
\begin{longtblr}[
theme = MyTheme, %<--- added
caption={Caption},
label={tab:label},
remark{Note}={I want this note on every page where the longtblr is}
]{%
hlines,
vlines,
colspec={X[l,m]},
}
\blindtext \\
\blindtext \\
\blindtext \\
\blindtext \\
\blindtext \\
\blindtext \\
\blindtext \\
\blindtext \\
\end{longtblr}
\end{document}


I would like to present an improved solution off Imran's solution. In my opinion, it is better to place the note (and remark) templates inside firstfoot and middlefoot and not in the contfoot-text template. This ensures the correct justification for multiline notes and remarks. Also, for consistency, one should use contfoot template and not hardcode the text.

I choose to specify this as default, but of course you can also use this in a theme as in Imran's solution.

\documentclass[12pt,a4paper]{book}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{tabularray}
\usepackage{blindtext}

% Notes and remarks on every page
\DefTblrTemplate{firstfoot, middlefoot}{default}{%
\UseTblrTemplate{note}{default}
\UseTblrTemplate{remark}{default}
\UseTblrTemplate{contfoot}{default}
}

\begin{document}
\begin{longtblr}[
caption={Caption},
label={tab:label},
remark{Note}={I want this note on every page where the longtblr is},
remark{Long Source}={This is a really long source, which will break over several lines. Using the correct templates ensures that the justification remains. With raggedright, the right side of multine notes and remarks will not be justified, which looks odd.}
]{%
hlines,
vlines,