Back to Website
Show / Hide Table of Contents

updateContainerSettings

  • Less than a minute to read

Updates settings of channel containers that implement spot colors and textures in Customer's Canvas. It is a full equivalent to container.update from the IFrame API.

This command allows you to change the settings by the container name. The type of containers cannot be changed.

Params

This command takes a <string, object> structure. Here, string is the container name and object represents new parameters for this container. You can change the following parameters:

  • name - the new name for the container.
  • translationKey - the translation key of the channel caption. You need to define such a caption in locales.json.
  • previewColor - a string in the CSS format. You can change the color for spotColor containers.
  • texture - a path to the texture image. You can change the color for texture containers.

For the complete list of parameters, you can refer to UpdateContainerSettingsCommand.

Example

This example supposes that product design has a texture container with the foil name.

{
    "type": "design-editor", 
    "name": "design-editor",
    "params": {
        "initial": { ... }, 
        "updateContainerSettings": [
            {
                'foil' : { "texture": "{{ $['texture']._.props.texture }}" } 
            }
        ]
     }
}
Was this page helpful?
Thanks for your feedback!
Back to top Copyright © 2001–2024 Aurigma, Inc. All rights reserved.
Loading...
    Thank for your vote
    Your opinion is important to us. To provide details, send feedback.
    Send feedback