basecamp / basecamp/trix

How can I set a custom figcaption in an attatchment uploded?

Open
#1,221 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
20k
Forks
1.1k
Avg merge
3d 12h
Merged PRs (30d)
13

Description

## Details
I have been trying to set a custom figcaption in this way

```
attrs["content"]= `



${attachment.file.name}
${attachment.getFormattedFilesize()}
Download
`
```

But for some reason when the it renders it keeps the figcaption generated by trix

![Image](https://github.com/user-attachments/assets/6412b5f7-b915-4f34-af85-45f03795dcad)

How can I add content to that figcaption generated by trix?

Contributor guide

No contributing guide indexed for this repository

Research direction

No project file, test, or entry point is identified in the issue. Start by reproducing the uploaded-video rendering and trace how Trix generates the attachment figcaption; done would mean documenting or implementing a supported way to add custom figcaption content.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.