How to customize the numbering of margin notes in Marginalia?

This is now possible!

I have now moved the numbering option to the #note[] function itself and added an anchor-numbering option in marginalia 0.2.1.

With this update, you can to do the following:

#import "@preview/marginalia:0.2.1" as marginalia: note

#set par(justify: true)

#show: marginalia.setup.with(
  outer: (width: 4cm, far: 2cm)
)
#let note = note.with(
  numbering: (.., i) => { strong[#i]; h(0.75em - 2pt) },
  anchor-numbering: (.., i) => super[#i],
  // having anchor-numbering != auto implies flush-numbering = true
)

#lorem(20)
#note[#lorem(10)]
#lorem(30)

// Or even

#show: marginalia.setup.with(
  outer: (sep: 1cm, width: 4cm, far: 2cm),
)

#lorem(20)
#note(flush-numbering: false)[#lorem(10)]
#lorem(30)

:]

5 Likes