TronDesigner - Integration Examples
Docs: Developer documentation  |  Examples overview  |  Quick start

All examples

Quick Start

Auto-opens the designer on page load using exact data.

Attributes - Overview

Opens the editor from data attributes on a button and wires every event callback through script attributes.

Init Failure Handling

Demonstrates handling SDK initialization failure with a notification popup.

Builder - Exact

Uses the JS args builder for an exact product + printing.

Builder - Partial

Starts with a model; user picks variants and printings.

JSON - Exact

Opens with a full explicit JSON payload.

JSON - Exact (Advanced)

Adds and removes product variants and printings on an existing print job using Edit mode.

Editor Options - Missing

Shows how showSelectedVariants / showSelectedPrintOptions react when sent variant or printing codes are not found in the catalogue.

JSON - Partial

Opens with a minimal JSON payload (model only).

JSON - Own Product

Opens using custom product data (Own schema) instead of PromoTron catalog.

Get Images

Retrieves motive area + visualization images after creation.

Result Action

Shows possible result action configurations, which determine what happens when the print graphics is confirmed.

Custom Editor Buttons

Opens the editor with one, two, or three custom footer buttons.

Edit Mode

Open and modify existing print jobs using their GUID.

View Mode

Display print jobs in read-only mode for review and confirmation.

URL Integration

Direct URL integration without JavaScript - perfect for emails and QR codes.

Inline Embed

Embed the editor directly into a page element for seamless integration.

Event Handling

Subscribes to all editor events (print job, logo, text, proofreading) and logs them, plus the onClose reason.

Session Tracking

Link print jobs to users, orders, and cart items for e-commerce integration.

Custom Properties

Attach arbitrary metadata to print jobs via HTML attribute, JS builder, or print job arguments, and verify the properties echo back in the created event.

Design Instructions

Show instructions to the customer in the editor via the EDITOR:DESIGN_INSTRUCTION custom property, and update or hide them in Edit mode.

Suggested Design Colors

Offer brand colors in the logo and text color selectors via EDITOR:DESIGN_COLOR_<n> custom properties, and automatically recolor logos when exactly one color is supplied.

Error Handling

Where errors are reported and how to handle them: onClose('Error'), getInitialized(), invalid custom buttons and rejected API calls.

Multiple Printings

Configure multiple print positions and technologies in a single print job.

Modify styles from host

Example of injecting custom CSS into the designer from the host page, to modify the editor's appearance and behavior.

Logo Features

Logo upload and gallery, the selected logo (logo.selected event), and preselecting a logo by GUID or URL.

Logo Visualization

Replaces product images with rendered logo visualizations using data-td-action="RenderVisualization" - by variant, and by variant + print position + technology across multiple products.