How can I use the tweaked version of biblatex-chicago (to conform with the style of the journal Isis) presented by @moewe here while using certain personal macros in the page field in \cite commands?
In particular, the journal Isis requires "p./pp." before page ranges. When citing page ranges, I often add line numbers, paragraph numbers, and note references. For example, if I am citing note 3 on page 42, I would write \cite[42 \note 3]{...}, with the following desired output (for a short book citation):
Author, Title, p. 42 n. 3
To complicate matters more, I sometimes refer to the page on which an endnote is printed (to save the reader some time), e.g., \cite[42 \note 3 printed on \pa 250]{...}:
Author, Title, p. 42 n. 3 printed on p. 250
The personal macros that I frequently use in the page field are:
\newcommand{\Line}[1]{\mbox{\textsubscript{#1}}}
\newcommand{\Lines}[2]{\mbox{\textsubscript{#1-#2}}}
\newcommand{\Linebot}[1]{\mbox{\textsubscript{⌂#1}}} % line number, counting from bottom
\newcommand{\Linesbot}[2]{\mbox{\textsubscript{⌂#1-⌂#2}}} % line range both counting from bottom
\newcommand{\Linestopbot}[2]{\mbox{\textsubscript{#1-⌂#2}}} % line range first from top, second from bottom
\newcommand\note{n.\unspace~} % note
\newcommand\notes{nn.\@ } % notes
\newcommand\para{¶} % paragraph
\newcommand\paras{¶}%{¶¶} % paragraphs
\newcommand\Para{¶} % Paragraph
\newcommand\Paras{¶}%{¶¶} % Paragraphs
\newcommand\pa{p.\unspace~} % page
\newcommand\pp{pp.\@\xspace} % pages
(See also the MWE below.)
The desired output I seek it to keep the prefixed "p./pp." even when those macros are used, but NOT when my page citation does not in fact include a page number, for example, when I cite a note without the page number \cite[\note 3]{...}:
Author, Title, n. 3
(or similarly when I cite a section [\S 4] or paragraph [\para 7] alone).
Is this possible? I have tried to fiddle with \PagesCheckSetup, \NumCheckSetup, and \DeclareNumChars, but clearly I don't understand exactly how they work.
MWE
\documentclass{article}
\usepackage{xspace}
\usepackage[notes]{biblatex-chicago}
% My macros
\xspaceaddexceptions{\ccc \Line \Lines \Linebot \Linesbot \Linestopbot}
\newcommand{\Line}[1]{\mbox{\textsubscript{#1}}}
\newcommand{\Lines}[2]{\mbox{\textsubscript{#1-#2}}}
\newcommand{\Linebot}[1]{\mbox{\textsubscript{⌂#1}}} % line number, counting from bottom
\newcommand{\Linesbot}[2]{\mbox{\textsubscript{⌂#1-⌂#2}}} % line range both counting from bottom
\newcommand{\Linestopbot}[2]{\mbox{\textsubscript{#1-⌂#2}}} % line range first from top, second from bottom
\newcommand\note{n.\unspace~} % note
\newcommand\notes{nn.@ } % notes
\newcommand\para{¶} % paragraph
\newcommand\paras{¶}%{¶¶} % paragraphs
\newcommand\Para{¶} % Paragraph
\newcommand\Paras{¶}%{¶¶} % Paragraphs
\newcommand\pa{p.\unspace~} % page
\newcommand\pp{pp.@\xspace} % pages
% moewe's earlier solution
\DeclareFieldFormat{jourvol}{\mkbibitalic{#1}}
\DeclareFieldFormat{journum}{\mkbibparens{#1}}%
\renewbibmacro*{cjournal+issue+year+pages}{%
\ifentrytype{periodical}%
{\usebibmacro{cperiodical+ser+vol+num}}%
{\usebibmacro{cjournal+ser+vol+num}}}
\renewbibmacro{cjournal+ser+vol+num}{%
\usebibmacro{journal+sub}%
\setunit{\addspace}%
\printlist[periodplace]{location}%
\setunit{\addspace}%
\iffieldundef{series}%
{}%
{\newcunit%
\printfield[jourser]{series}%
\newcunit}%\setunit{\addspace}?
\newcunit
\iffieldundef{issue}%
{\usebibmacro{number+or+month}}%
{\printfield{issue}%
\setunit{\addspace}%
\usebibmacro{cmsyear}}%
\newcunit
\printfield[jourvol]{volume}%
\printfield[journum]{number}%
\setunit{\postvolpunct}}% Moved eid for 17th ed.
\DefineBibliographyStrings{english}{
thiscite = {on},
}
\AtEveryCitekey{\savefield{postnote}{\cbxsavepostnote}\clearfield{postnote}}
\DeclareFieldFormat{pages}{%
\ifboolexpr{%
togl {cms@comprange}%
and
test {\ifpages{#1}}%
}%
{\mkpageprefix[bookpagination][\mkcomprange]{#1}}%
{\mkpageprefix[bookpagination][\mknormrange]{#1}}}
\DeclareFieldFormat[article,periodical]{pages}{%
\ifboolexpr{%
togl {cms@comprange}%
and
test {\ifpages{#1}}%
}%
{\mkcomprange{#1}}%
{\mknormrange{#1}}}
\DeclareFieldFormat{postnote}{%
\ifboolexpr{%
togl {cms@comprange}%
and
test {\ifpages{#1}}%
}%
{\mkpageprefix[pagination][\mkcomprange]{#1}}%
{\mkpageprefix[pagination][\mknormrange]{#1}}}
\renewbibmacro*{postnote}{%
\restorefield{postnote}{\cbxsavepostnote}%
\iffieldundef{postnote}
{}
{\setunit{\addcomma\space}%
\iftoggle{cms@fullnote}
{\iffieldundef{pages}
{}
{\iffieldpages{postnote}
{\bibstring{thiscite}%
\setunit{\addspace}}
{}}}
{}%
\printfield{postnote}}}
% MY ADDITION IN AN ATTEMPT TO KEEP PAGE REFS
%\PagesCheckSetup{\def\Line{}\def\Lines{}\def\pa{}\def\pp{}}
%\NumCheckSetup{\def\Line{}\def\Lines{}\def\pa{}\def\pp{}}
%\DeclareNumChars{}
\addbibresource{biblatex-examples.bib}
\begin{document}
\cite{westfahl:space}.
\mancite
\cite[32]{westfahl:space}.
\mancite
\cite[32\Lines{3}{9}]{westfahl:space}.
\mancite
\cite[32 \note 3]{westfahl:space}.
\end{document}
Current output:
Desired output is for the last three lines to be:
Westfahl, “The True Frontier,” p. 32.
Westfahl, “The True Frontier,” p. 32_{3-9}.
Westfahl, “The True Frontier,” p. 32 n. 3.
Where _{...} stands for subscript.

westfahl:space! – Alex Roberts Mar 25 '21 at 12:13\cite[\pno~32 \note 3]{westfahl:space}.? – Ulrike Fischer Mar 25 '21 at 12:24\citescommand on other occasions then you can solve with\cites(\note 3)[32]{westfahl:space}e\cites(\Lines{3}{9})[32]{westfahl:space}. You will need to modyfy\noteand\multipostnotedelim:\newcommand\note{\addspace n. \ unspace~} \DeclareDelimFormat{multipostnotedelim}{}– Ivan Mar 25 '21 at 14:33\pnoin my cite commands because usually I use a different citation style (Chicago style) that omits "p./pp." before most page references. But the journal Isis requires "p./pp.", so I was hoping to have them automatically added, even when I use\Linesor\noteor my other personal macros. This would make it easier to switch between this style and Chicago (my hope is that it will also help others in the future in a similar situation). – Alex Roberts Mar 26 '21 at 11:35\cite[5 n.~2]{...}). – Alex Roberts Mar 26 '21 at 11:40\pno~and then you can either later redefine or remove it by search and replace. – Ulrike Fischer Mar 26 '21 at 12:01