API reference
Asset: Test
Design
addAudioTrackaddElementAtCursoraddElementAtPointaddPageapplyTemplateautofillDesignbulkCreate.launchcreateRichtextRangeeditContentgetBrandKitColorsgetBrandTemplateMetadatagetCurrentPageContextgetCurrentPageMetadatagetDesignColorsgetDesignMetadatagetDesignTemplateMetadatagetDesignTokeninitAppElementopenDesignoverlay.registerOnCanOpenpublish.launchrequestBrandTemplatesrequestDataFieldMatchingrequestExportselection.registerOnChangesetCurrentPageBackgroundsetDataFieldLabelVisibilityui.startDragToCursorui.startDragToPointChangelog
Design: Test
Intents
Intents: Asset
Intents: Content
Intents: Data
Intents: Design
Intents: Test
Platform
appProcessappProcess.broadcastMessageappProcess.currentappProcess.current.getInfoappProcess.current.requestCloseappProcess.current.setOnDisposeappProcess.requestCloseappProcess.registerOnMessageappProcess.registerOnStateChangefeatures.isSupportedfeatures.registerOnSupportChangegetPlatformInfonotification.addToastrequestOpenExternalUrlChangelog
Platform: Test
User: Test
App middleware: Express
Error
Error: Test
setDataFieldLabelVisibility
API reference for the setDataFieldLabelVisibility method.
This API is a preview. Preview APIs are unstable and may change without warning. You can't release public apps using this API until it's stable.
Controls whether data field labels are visible in the editor for the current app session. When enabled, users can see the purple labels indicating which data field each tagged element is linked to. The setting resets to hidden once the app session ends.
Usage: Show data field labels, then hide them again
import { setDataFieldLabelVisibility } from "@canva/design";await setDataFieldLabelVisibility({ visible: true });// User reviews data field labels in the editor.await setDataFieldLabelVisibility({ visible: false });
TYPESCRIPT
Parameters
optsSetDataFieldLabelVisibilityOptionsRequired
The configuration options for this call.
visiblebooleanRequired
Whether data field labels should be visible in the editor for the current app session.
Returns
Response object from a setDataFieldLabelVisibility call. This is a Promise that resolves with the following object:
statusstringThe only valid value is "completed".