Hi, from the docs:
Currently, labels can only be attached to elements in markup mode, not in code mode. This might change in the future.
Which means it works if you use square brackets for your code inside context
.
#context[
#figure(
my_table, caption: flex-caption([This is the table caption], [This is the outline caption])
) <link_my_table>
]