Skip to content

Added text files reader#116

Merged
veronika-tseleva-cleantalk merged 2 commits into
devfrom
text-files-reader
Jun 19, 2026
Merged

Added text files reader#116
veronika-tseleva-cleantalk merged 2 commits into
devfrom
text-files-reader

Conversation

@veronika-tseleva-cleantalk

Copy link
Copy Markdown
Contributor

Copilot AI review requested due to automatic review settings June 19, 2026 02:54

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds support for opening “text-like” attachments (code/config/log files) in a lightbox, using Ace Editor for syntax highlighting, and includes a small date-formatting guard to avoid errors on missing timestamps.

Changes:

  • Classify attachments as image vs text to decide whether to open in an image lightbox, text lightbox, or download.
  • Add a text lightbox implementation that fetches the file content and renders it in Ace Editor.
  • Guard date formatting against falsy inputs (but currently returns undefined, see comments).

Reviewed changes

Copilot reviewed 3 out of 6 changed files in this pull request and generated 3 comments.

File Description
styles/doboard-widget.css Adds new lightbox styles intended for text viewer (currently overrides existing image lightbox styles).
js/src/widget.js Adds text-file detection + Ace-based text lightbox and routes clicks accordingly.
js/src/handlers.js Updates formatToDotMonthDate to handle missing input (needs a safe default return).
dist/doboard-widget-bundle.js Rebuilt bundle reflecting the above source/style changes.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread styles/doboard-widget.css Outdated
Comment thread js/src/widget.js Outdated
Comment thread js/src/handlers.js
@veronika-tseleva-cleantalk veronika-tseleva-cleantalk merged commit 1da53ee into dev Jun 19, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants