release: WRNexusJS 0.8.0
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
component RealtimeRoom {
|
||||
props {
|
||||
room: string = ""
|
||||
user: string = ""
|
||||
title: string = "Conversation"
|
||||
description: string = ""
|
||||
statusLabel: string = "Connecting…"
|
||||
emptyLabel: string = "No messages yet."
|
||||
color: string = "primary"
|
||||
size: string = "md"
|
||||
class: string = ""
|
||||
}
|
||||
|
||||
view {
|
||||
<Card
|
||||
{...attrs}
|
||||
title='{title}'
|
||||
description='{description}'
|
||||
color='{color}'
|
||||
size='{size}'
|
||||
class='{class}'
|
||||
>
|
||||
<section data-room='{room}' data-room-user='{user}' class="flex min-h-72 flex-col gap-4">
|
||||
<RoomStatus label='{statusLabel}' color='{color}' size='{size}' />
|
||||
<div data-room-log role="log" aria-live="polite" class="flex min-h-40 flex-1 flex-col gap-3 overflow-y-auto rounded-[var(--wire-radius-sm)] bg-[var(--wire-color-surface-2)] p-3">
|
||||
<p data-room-empty class="m-auto text-sm text-[var(--wire-color-muted)]">{emptyLabel}</p>
|
||||
<slot></slot>
|
||||
</div>
|
||||
<slot name="composer"></slot>
|
||||
</section>
|
||||
</Card>
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user