Frontend API

Main entry point of frontend API to register new content element types.

Members
frontend.contentElementTypes
frontend.widgetTypes

Editor API

Main entry point of editor API to register new content element types.

Members
editor.contentElementTypes

Components

React components for building content elements.

Members
<AudioPlayer audioFile posterImageFile? defaultTextTrackFileId? load? props />
<ContentElementBox children />
<Figure children caption onCaptionChange addCaptionButtonVisible captionButtonPosition addCaptionButtonPosition />
<FitViewport file? aspectRatio? opaque? fill? scale = 1 children />
<Image imageFile variant? load? structuredData? preferSvg? fill props />
<Text inline? scaleCategory children />
<ThemeIcon name width height />
ThirdPartyOptIn
ThirdPartyOptOutInfo
<VideoPlayer videoFile posterImageFile? defaultTextTrackFileId? load? fit? props />

Hooks

React hooks to obtain entry data.

Members
useAdditionalSeedData(name)
useAudioFocus(options)
useContentElementEditorState()
useContentElementLifecycle(options, onActivate, onDeactivate)
useCurrentChapter()
useCredits()
useDarkBackground()
useEntryMetadata()
useFile(options)
useFileRights()
useI18n($0, options?, locale)
useIsStaticPreview()
useLegalInfo()
useMediaMuted()
usePortraitOrientation(options)
useShareProviders($0)
useShareUrl()
useTheme()

Frontend Helpers

Helper functions that can be used in content elements.

Members
paletteColor(value)

Spec Support

Helper functions to use in specs.

Members
normalizeSeed(options = {})
renderInEntry(ui, options = {})
renderHookInEntry(callback, options = {})

Storybook Support

Helper functions to use in content element stories.

Members
filePermaId(collectionName, testReferenceName)
storiesOfContentElement(module, options, typeName, baseConfiguration, variants, consent)

ContentElementFigure

<ContentElementFigure configuration: Object children: string />
Props
Name Description
configuration Object Configuration of the content element.
children string Content of box.