Inline Message

Show contextual feedback near an input or action element.

Live preview
Interact with the component to see results here.
View code
HTML
<div style="display:inline-flex;align-self:center;margin:35px 0">
  <sy-button>View help</sy-button>
  <sy-inline-message
    message="Save your changes before continuing."
    variant="informational"
    placement="bottom"
    icon
    btnlabel="Confirm"
    id="sample"
  ></sy-inline-message>
</div>

Usage guide

#

Show input errors or help near the related element. Use Banner for broad notices and Toast for brief completion feedback.

  1. Place inside the target element

    Place it inside the parent that acts as the trigger. The message is portaled into the body, but its position follows that parent.

  2. Connect content and actions

    Set the content with message and offer a follow-up action through btnLabel or the action slot.

  3. Choose when to show it

    Manage visibility through clicks, focus departure, or show() and hide(). Clicking outside closes it.

Feature examples

#

Choose a feature from 12 topics. Explore property settings, method calls, event results, and slot layouts through live examples and code.

Usage examples · Overview

Try the selected example. Topics with multiple configurations let you switch between detailed examples.

View code
HTML
Loading the example.

Property · Animation

See how settings change appearance and behavior.

View code
HTML
Loading the example.

Property · AnimationSpeed

See how settings change appearance and behavior.

View code
HTML
Loading the example.

Property · Btn Label

See how settings change appearance and behavior.

View code
HTML
Loading the example.

Property · Message

See how settings change appearance and behavior.

View code
HTML
Loading the example.

Property · Open

See how settings change appearance and behavior.

View code
HTML
Loading the example.

Property · Position

See how settings change appearance and behavior.

View code
HTML
Loading the example.

Property · Show Icon

See how settings change appearance and behavior.

View code
HTML
Loading the example.

Property · Sticky

See how settings change appearance and behavior.

View code
HTML
Loading the example.

Property · Trigger

See how settings change appearance and behavior.

View code
HTML
Loading the example.

Property · Variant

See how settings change appearance and behavior.

View code
HTML
Loading the example.

Events · Btn Click

Interact with the component to see event names and payloads in the live preview below.

View code
HTML
Loading the example.

API reference

#

Hover over a name or focus it with the keyboard to see the code. On touch screens, tap the name.

<sy-inline-message>

Properties

Attribute / PropertyTypeDefaultDescription
'informational' | 'info' | 'success' | 'warning' | 'error''informational'Component display style.
string'Inline message'Help text about the input state.
booleantrueShow the status icon.
booleanundefinedShow the status icon.
booleanfalseShow an action button in the message.
booleanfalseShow the contextual help popup.
'click' | 'focusout''click'click toggles it when the parent is clicked. focusout shows it when focus leaves the parent.
string''Action button text.
'top' | 'bottom' | 'left' | 'right''bottom'Preferred popup position relative to the trigger.
'top' | 'bottom' | 'left' | 'right'undefinedItem layout direction.
booleanfalseKeep the popup visible when the parent scrolls out of view.
| 'none' | 'fade' | 'fade-scale' | 'zoom' | 'pop' | 'slide-top' | 'slide-bottom' | 'slide-left' | 'slide-right' | 'slide-fade-top' | 'slide-fade-bottom' | 'slide-fade-left' | 'slide-fade-right' | 'reveal-top' | 'reveal-bottom' | 'reveal-left' | 'reveal-right' | 'flip-x' | 'flip-y' | 'bounce' | 'spin''none'Enter/exit animation type. `none` (default) toggles instantly.
'x-fast' | 'fast' | 'medium' | 'slow' | 'x-slow''fast'Animation playback speed token. Maps to `--transition-*` global tokens.

Events

EventDetailDescription
CustomEvent<MouseEvent>Read the result from the event's detail.
CustomEvent<MouseEvent>Read the result from the event's detail.
CustomEvent<void>Read the result from the event's detail.

Methods

MethodReturnsDescription
Promise<void>Show the notification.
Promise<void>Hide the currently displayed notification.

Slots

SlotDescription
Content displayed in the action area.