Message - Writer AI Studio

Overview

The Message component displays status messages, notifications, and feedback to users. It uses prefix characters to determine the message type and styling automatically. Message components support different types (success, error, warning, loading, info) with appropriate styling and can display dynamic content from state variables. They’re essential for creating responsive, user-friendly interfaces that keep users informed.

Common use cases

How it works

  1. Message content: Display static text or reference state variables
  2. Prefix-based types: Use prefix characters to determine message type automatically. For example, + makes the message green, - makes it red, and % provides a dynamic loading icon.
  3. Dynamic updates: Content updates automatically when state variables change
  4. Visual styling: Each message type has distinct colors and styling
  5. Conditional display: Messages can show or hide based on conditions

The component provides immediate feedback to users about the state of their interactions and system operations.

Configuration options

Basic settings

Message types and prefixes

Styling options

Example

Processing status updates

Create a workflow that shows different status messages during file processing.

Interface:

Message configuration:

Best practices

  1. Clear messaging: Use concise, clear language that users can understand immediately
  2. Appropriate types: Choose the correct message type for the content (info, success, warning, error)
  3. Dynamic content: Use state variables to show relevant, up-to-date information
  4. Conditional display: Show messages only when relevant to avoid interface clutter
  5. Consistent styling: Maintain consistent message styling across your interface
  6. Context: Provide enough context for users to understand and act on the message

Fields

Name Type Description Options
Message Text Prefix with ’+’ for a success message, with ’-’ for error, ’!’ for warning, ’%’ for loading. No prefix for info. Leave empty to hide. -
Success Color - -
Error Color - -
Warning Color - -
Info Color - -
Loading Color - -
Primary text Color - -
Custom CSS classes Text CSS classes, separated by spaces. You can define classes in custom stylesheets. -