Comments
Description
Comments cards and inline comment threads for Enso UI.
Installation
Install the package:
yarn add @enso-ui/comments
This package is also available through the full enso-ui workspace bundle.
Features
- exports
CommentsandCommentsCardthrough the Bulma entrypoint - loads comment threads, supports optimistic create/delete/update flows, and keeps tagged users in sync
- ships inline edit and delete actions with the Enso confirmation popper
- surfaces comment counts through the card wrapper used on entity detail pages
Usage
<script setup>
import { CommentsCard } from '@enso-ui/comments/bulma';
</script>
<CommentsCard
:id="companyId"
type="company"
title="Comments"
/>
API
Comments
Thread component that manages the comment list for one model.
Import: @enso-ui/comments/bulma
Props:
id: string | numbertarget model id.type: stringbackend commentable type.query: string | null = nullinitial filter.compact: boolean = falsetoggles compact toolbar labels.
Events:
updateafter fetch, create, or delete operations.
Slots:
controlsreceives{ create, internalQuery, fetch }.
CommentsCard
Card wrapper around Comments with badge and refresh controls.
Import: @enso-ui/comments/bulma
Props:
collapsed: boolean = falseid: string | numbertype: stringtitle: string = ""icon: string | array | object
Events:
- No direct emits.
Companion Backend Package
The frontend widgets depend on the backend companion for comment thread endpoints, tagged-user support, and the model-type contracts used by the card.
Depends On
Contributions
are welcome. Pull requests are great, but issues are good too.
Thank you to all the people who already contributed to Enso!