How to bold text and math in the first row of a Table for a template?

I have defined a function that acts as a template for a table such that I can have the same style easily in my whole document. In this template, I want the entries of the first line to be bold face and white, both text and math.

Using the code below, the math part doesn’t “inherit” the bold face of the text but it does inherit the white fill of the font. Why doesn’t it inherit the bold property? And how can I make that happen?

#let my_table(..args) = {
  show table.cell.where(y:0): set text(fill: white, weight: "bold")
  show table.cell: set align(horizon)
  table(
    rows: (2.5em, 1.5em),
    inset: 5pt,
    fill: (x,y) => (if y == 0 {(rgb("#984A9C"))} else {}),
    stroke: (x,y) => ( bottom: if y > 0 {0.5pt + rgb("#984A9C")} else {0pt}),
    ..args,
  )
}

#{
  my_table(
    columns: 5,
    align: center,
    [$n$], [$α$], [$β_"i"$],[four\ (-)], [five],
      [1],[55.72],[2.15e-4], [54.28 ],[7.3e-5],
      [2],[22.72],[1.424e-3], [23.04 ],[6.26e-4],
  )
}


Use show table.cell.where(y: 0): strong. Inconsistent interaction between bold text and math · Issue #5385 · typst/typst · GitHub

Thanks for the quick answer. However, I’m using Touying and strong is defined as more than “just bold”: it also changes the font color… Can I locally override strong? Or can I define a my_strong?

Disable it then:

#import "@preview/touying:0.6.1": *
#import themes.simple: *
#show: simple-theme.with(config-common(show-strong-with-alert: false))

= Heading 1
== Heading 2
*Strong* text.

Or use text directly:

#import "@preview/touying:0.6.1": *
#import themes.simple: *
#show: simple-theme
#let bold = text.with(weight: "bold")

= Heading 1
== Heading 2
#bold[Strong] text.

I would’ve linked docs, but there is none, other than source files. Add searchable API reference documentation · Issue #222 · touying-typ/touying · GitHub