// Count labels. #let label = #let count = counter(label).display() #let elem(it) = [#box(it) #label] #elem[hey, there!] #count \ #elem[more here!] #count