close

Filter

loading table of contents...

Studio Developer Manual / Version 2406.0

Table Of Contents

9.5.5 Disabling Preview for Specific Content Types

For some content types a suitable preview representation is not easily generated. This applies to some built-in content types like Dictionary and EditorPreferences, but also to very technical content types storing CSS or script code.

The method getDocumentTypesWithoutPreview() from the global @coremedia/studio-client.main.editor-components/sdk/editorContext grants access to an array of content type names for which no preview should be shown. Like in the case of content types excluded from creation as shown in the previous section, you can simply push additional content types into the mutable array returned from the method.

You can also use the ConfigureDocumentTypes plugin to specify content types without preview, like in the following excerpt from BlueprintFormsStudioPlugin.ts.

import ConfigureDocumentTypes from "@coremedia/studio-client.main.editor-components/configuration/ConfigureDocumentTypes";

//...
new ConfigureDocumentTypes({
    names: "CMAction,CMCSS,...",
    preview: false,
})

Example 9.25. Defining content types without preview


Search Results

Table Of Contents
warning

Your Internet Explorer is no longer supported.

Please use Mozilla Firefox, Google Chrome, or Microsoft Edge.