Documentation
LayoutGlass surface
MessageScroller
Provides a scrollable message feed.
01
See it in context
Preview
02
Copy a working example
Usage
---
import {
Avatar,
Bubble,
Message,
MessageScroller
} from '@santi020k/lumen-astro'
---
<MessageScroller aria-label="Conversation" style="max-height: 14rem;">
<Message>
<Avatar fallback="LU" />
<Bubble>Lumen components are installed and ready.</Bubble>
</Message>
<Message from="user">
<Avatar fallback="SM" />
<Bubble from="user">Show me the Button docs.</Bubble>
</Message>
<Message>
<Avatar fallback="LU" />
<Bubble>The Button primitive includes variants for common product actions.</Bubble>
</Message>
<Message from="user">
<Avatar fallback="SM" />
<Bubble from="user">Can I pair it with an icon?</Bubble>
</Message>
<Message>
<Avatar fallback="LU" />
<Bubble>Yes. Use the button for the action and place the icon beside the label.</Bubble>
</Message>
<Message from="user">
<Avatar fallback="SM" />
<Bubble from="user">Perfect, ship the example.</Bubble>
</Message>
</MessageScroller>---
import {
Avatar,
Bubble,
Message,
MessageScroller
} from '@santi020k/lumen-astro'
---
<MessageScroller aria-label="Conversation" style="max-height: 14rem;">
<Message>
<Avatar fallback="LU" />
<Bubble>Lumen components are installed and ready.</Bubble>
</Message>
<Message from="user">
<Avatar fallback="SM" />
<Bubble from="user">Show me the Button docs.</Bubble>
</Message>
<Message>
<Avatar fallback="LU" />
<Bubble>The Button primitive includes variants for common product actions.</Bubble>
</Message>
<Message from="user">
<Avatar fallback="SM" />
<Bubble from="user">Can I pair it with an icon?</Bubble>
</Message>
<Message>
<Avatar fallback="LU" />
<Bubble>Yes. Use the button for the action and place the icon beside the label.</Bubble>
</Message>
<Message from="user">
<Avatar fallback="SM" />
<Bubble from="user">Perfect, ship the example.</Bubble>
</Message>
</MessageScroller>import { Avatar, Bubble, Message, MessageScroller } from '@santi020k/lumen-react'
export const Example = () => (
<>
<MessageScroller aria-label="Conversation" style={{ maxHeight: '14rem' }}>
<Message>
<Avatar fallback="LU" />
<Bubble>Lumen components are installed and ready.</Bubble>
</Message>
<Message from="user">
<Avatar fallback="SM" />
<Bubble from="user">Show me the Button docs.</Bubble>
</Message>
<Message>
<Avatar fallback="LU" />
<Bubble>The Button primitive includes variants for common product actions.</Bubble>
</Message>
<Message from="user">
<Avatar fallback="SM" />
<Bubble from="user">Can I pair it with an icon?</Bubble>
</Message>
<Message>
<Avatar fallback="LU" />
<Bubble>Yes. Use the button for the action and place the icon beside the label.</Bubble>
</Message>
<Message from="user">
<Avatar fallback="SM" />
<Bubble from="user">Perfect, ship the example.</Bubble>
</Message>
</MessageScroller>
</>
)import { Avatar, Bubble, Message, MessageScroller } from '@santi020k/lumen-react'
export const Example = () => (
<>
<MessageScroller aria-label="Conversation" style={{ maxHeight: '14rem' }}>
<Message>
<Avatar fallback="LU" />
<Bubble>Lumen components are installed and ready.</Bubble>
</Message>
<Message from="user">
<Avatar fallback="SM" />
<Bubble from="user">Show me the Button docs.</Bubble>
</Message>
<Message>
<Avatar fallback="LU" />
<Bubble>The Button primitive includes variants for common product actions.</Bubble>
</Message>
<Message from="user">
<Avatar fallback="SM" />
<Bubble from="user">Can I pair it with an icon?</Bubble>
</Message>
<Message>
<Avatar fallback="LU" />
<Bubble>Yes. Use the button for the action and place the icon beside the label.</Bubble>
</Message>
<Message from="user">
<Avatar fallback="SM" />
<Bubble from="user">Perfect, ship the example.</Bubble>
</Message>
</MessageScroller>
</>
)<script type="module">
import { defineLumenElements } from '@santi020k/lumen-elements/define'
defineLumenElements()
</script>
<lumen-message-scroller aria-label="Conversation" style="max-height: 14rem;">
<lumen-message>
<lumen-avatar fallback="LU"></lumen-avatar>
<lumen-bubble>Lumen components are installed and ready.</lumen-bubble>
</lumen-message>
<lumen-message from="user">
<lumen-avatar fallback="SM"></lumen-avatar>
<lumen-bubble from="user">Show me the Button docs.</lumen-bubble>
</lumen-message>
<lumen-message>
<lumen-avatar fallback="LU"></lumen-avatar>
<lumen-bubble>The Button primitive includes variants for common product actions.</lumen-bubble>
</lumen-message>
<lumen-message from="user">
<lumen-avatar fallback="SM"></lumen-avatar>
<lumen-bubble from="user">Can I pair it with an icon?</lumen-bubble>
</lumen-message>
<lumen-message>
<lumen-avatar fallback="LU"></lumen-avatar>
<lumen-bubble>Yes. Use the button for the action and place the icon beside the label.</lumen-bubble>
</lumen-message>
<lumen-message from="user">
<lumen-avatar fallback="SM"></lumen-avatar>
<lumen-bubble from="user">Perfect, ship the example.</lumen-bubble>
</lumen-message>
</lumen-message-scroller><script type="module">
import { defineLumenElements } from '@santi020k/lumen-elements/define'
defineLumenElements()
</script>
<lumen-message-scroller aria-label="Conversation" style="max-height: 14rem;">
<lumen-message>
<lumen-avatar fallback="LU"></lumen-avatar>
<lumen-bubble>Lumen components are installed and ready.</lumen-bubble>
</lumen-message>
<lumen-message from="user">
<lumen-avatar fallback="SM"></lumen-avatar>
<lumen-bubble from="user">Show me the Button docs.</lumen-bubble>
</lumen-message>
<lumen-message>
<lumen-avatar fallback="LU"></lumen-avatar>
<lumen-bubble>The Button primitive includes variants for common product actions.</lumen-bubble>
</lumen-message>
<lumen-message from="user">
<lumen-avatar fallback="SM"></lumen-avatar>
<lumen-bubble from="user">Can I pair it with an icon?</lumen-bubble>
</lumen-message>
<lumen-message>
<lumen-avatar fallback="LU"></lumen-avatar>
<lumen-bubble>Yes. Use the button for the action and place the icon beside the label.</lumen-bubble>
</lumen-message>
<lumen-message from="user">
<lumen-avatar fallback="SM"></lumen-avatar>
<lumen-bubble from="user">Perfect, ship the example.</lumen-bubble>
</lumen-message>
</lumen-message-scroller>03
Choose your target
Add this component
Choose the package for your runtime. All adapters share the Lumen stylesheet. Use the matching registry command when you want a local wrapper for that framework.
pnpm add @santi020k/lumen-astropnpm add @santi020k/lumen-astrolumen add MessageScrollerlumen add MessageScrollerpnpm add @santi020k/lumen-reactpnpm add @santi020k/lumen-reactlumen add MessageScroller --target reactlumen add MessageScroller --target reactpnpm add @santi020k/lumen-elementspnpm add @santi020k/lumen-elementslumen add MessageScroller --target elementslumen add MessageScroller --target elementsGlass
Add the glass prop to apply the shared blur, saturation, border, and highlight tokens. Glass reads best over vivid content, so place the surface above imagery or color.
---
import { Bubble, Message, MessageScroller } from '@santi020k/lumen-astro'
---
<div class="docs-glass-demo">
<MessageScroller glass style="--ui-list-height: 13rem;">
<Message><Bubble>The scroller frame is frosted; bubbles inside go translucent too.</Bubble></Message>
<Message from="user"><Bubble from="user">So the whole thread reads as one pane of glass?</Bubble></Message>
<Message><Bubble>Exactly - one backdrop-filter on the frame, tokenized tints inside.</Bubble></Message>
</MessageScroller>
</div>---
import { Bubble, Message, MessageScroller } from '@santi020k/lumen-astro'
---
<div class="docs-glass-demo">
<MessageScroller glass style="--ui-list-height: 13rem;">
<Message><Bubble>The scroller frame is frosted; bubbles inside go translucent too.</Bubble></Message>
<Message from="user"><Bubble from="user">So the whole thread reads as one pane of glass?</Bubble></Message>
<Message><Bubble>Exactly - one backdrop-filter on the frame, tokenized tints inside.</Bubble></Message>
</MessageScroller>
</div>import { Bubble, Message, MessageScroller } from '@santi020k/lumen-react'
export const Example = () => (
<>
<div className="docs-glass-demo">
<MessageScroller glass style={{ -UiListHeight: '13rem' }}>
<Message><Bubble>The scroller frame is frosted; bubbles inside go translucent too.</Bubble></Message>
<Message from="user"><Bubble from="user">So the whole thread reads as one pane of glass?</Bubble></Message>
<Message><Bubble>Exactly - one backdrop-filter on the frame, tokenized tints inside.</Bubble></Message>
</MessageScroller>
</div>
</>
)import { Bubble, Message, MessageScroller } from '@santi020k/lumen-react'
export const Example = () => (
<>
<div className="docs-glass-demo">
<MessageScroller glass style={{ -UiListHeight: '13rem' }}>
<Message><Bubble>The scroller frame is frosted; bubbles inside go translucent too.</Bubble></Message>
<Message from="user"><Bubble from="user">So the whole thread reads as one pane of glass?</Bubble></Message>
<Message><Bubble>Exactly - one backdrop-filter on the frame, tokenized tints inside.</Bubble></Message>
</MessageScroller>
</div>
</>
)<script type="module">
import { defineLumenElements } from '@santi020k/lumen-elements/define'
defineLumenElements()
</script>
<div class="docs-glass-demo">
<lumen-message-scroller glass style="--ui-list-height: 13rem;">
<lumen-message><lumen-bubble>The scroller frame is frosted; bubbles inside go translucent too.</lumen-bubble></lumen-message>
<lumen-message from="user"><lumen-bubble from="user">So the whole thread reads as one pane of glass?</lumen-bubble></lumen-message>
<lumen-message><lumen-bubble>Exactly - one backdrop-filter on the frame, tokenized tints inside.</lumen-bubble></lumen-message>
</lumen-message-scroller>
</div><script type="module">
import { defineLumenElements } from '@santi020k/lumen-elements/define'
defineLumenElements()
</script>
<div class="docs-glass-demo">
<lumen-message-scroller glass style="--ui-list-height: 13rem;">
<lumen-message><lumen-bubble>The scroller frame is frosted; bubbles inside go translucent too.</lumen-bubble></lumen-message>
<lumen-message from="user"><lumen-bubble from="user">So the whole thread reads as one pane of glass?</lumen-bubble></lumen-message>
<lumen-message><lumen-bubble>Exactly - one backdrop-filter on the frame, tokenized tints inside.</lumen-bubble></lumen-message>
</lumen-message-scroller>
</div>API reference
Lumen-specific props and runtime attributes for the Astro primitive. React props follow the same names; Elements use equivalent kebab-case attributes where custom elements expose them.
| Attribute | Values | Default | Description |
|---|---|---|---|
| glass | boolean | "subtle" | "strong" | false | Applies the tokenized liquid-glass surface treatment with backdrop-filter fallbacks; "subtle" and "strong" adjust the fill intensity. |
| class, className | string | "" | Merges custom classes with the generated ui-* root classes. |
| ...native attributes | HTML attributes | - | Forwards standard attributes to the root element unless the component consumes them. |