mirror of
https://github.com/vector-im/element-web.git
synced 2026-05-05 04:06:44 +02:00
doc: add for sub in SubstitutionValue
This commit is contained in:
parent
520dfffc95
commit
91d153aca3
@ -20,6 +20,11 @@ export type Translations = Record<
|
||||
|
||||
/**
|
||||
* The value a variable or tag can take for a translation interpolation.
|
||||
*
|
||||
* When used as a function, `sub` is the text content wrapped between the tag
|
||||
* in the translation string. For example, given `"Click <a>here</a>"`, the
|
||||
* function receives `"here"` and should return a `ReactNode` wrapping it.
|
||||
*
|
||||
* @public
|
||||
*/
|
||||
export type SubstitutionValue = number | string | ReactNode | ((sub: string) => ReactNode);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user