Skip to content

Conversation

@GuilhermeMorais
Copy link
Contributor

This pull request adds the ability to rename plugin instances within a playlist, including backend API support, model logic, and frontend UI/UX. It introduces a new modal dialogue for renaming, updates the playlist template to allow triggering the rename flow, and ensures proper validation and error handling throughout the stack.

Additionally, it enables Flask debug mode in development. However, this helps to pick up HTML changes, but changes in the managers are not picked up.

I added a new button:
image

And a new modal:
image

🎯 I try to keep any PR as small as possible so it's easy to review/work/approve them.
🥇 I hope to create a few more PR's during the Christmas time.

Rename Plugin Instance Feature

Backend support:

  • Added a new POST API route rename_plugin in playlist.py to handle renaming plugin instances, including input validation and error handling.
  • Implemented rename_plugin_instance method in the playlist manager model to update the plugin instance name within a playlist.

Frontend integration:

  • Updated playlist.html to add a "Rename" button next to each plugin instance, which opens a new modal for renaming.
  • Added a new modal dialogue (RenameModal) and supporting JavaScript functions (openRenameModal, renamePluginInstance, and modal management improvements) to handle the renaming workflow in the UI. [1] [2] [3]

Development Experience

  • Enabled Flask debug mode automatically when running in development mode in inkypi.py.

@GuilhermeMorais GuilhermeMorais changed the title New Funcionality: Rename Pluging New Funcionality: Rename Plugin Instance Dec 27, 2025
@GuilhermeMorais
Copy link
Contributor Author

Hello @fatihak, sorry to quote you, but I was wondering if I should ask for a review on the PR or just leave it open.

@fatihak
Copy link
Owner

fatihak commented Jan 29, 2026

Thanks for the PR! I think renaming plugins is a nice feature, but I have two items for feedback:

  • With the addition of the button to edit refresh settings, I don't like having another button for renaming a plugin. I think the renaming/editing refresh settings should be one button & modal to match the "Add to Playlist" and "Save As" button/modal when first saving a plugin
  • Each time a plugin instance generates an image the latest image is saved to memory in the refresh_task. This allows us to display the latest image if a plugin doesn't need to be refreshed, and also display the latest image in the playlist UI. This file would also need to be renamed so we don't have untracked files that are leftover when a plugin is renamed.

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.

2 participants