Bixby Developer Center

References

template-macro-def

requiredvalue required

Define a pattern to use as a dialog macro, which aids in avoiding duplicated dialog logic.

Note

This key will be deprecated in a future release. You should switch to using generic macro and macro-def keys instead to create dialog macros. For more information, see Reusing Content with Macros.

For more information about dialog macros, see Reusing Content with Macros.

You can define one or more template-macro-def keys within a *.dialog.bxb file. These files should be located in the appropriate locale-specific resources folder.

Example

// resources/en/dialog-macros/my-template.dialog.bxb
template-macro-def (id) {
params {
param (x) {
type (Boolean)
}
param (y) {
type (Text)
}
}

content {
if (x) {
template ("#{y}")
} else {
template ("something else")
}
}
}

Child Keys

content
required
Specify the content of a dialog macro
params
optional
Specify the parameters to pass in as part of a dialog macro definition