New: Show Remote Duration in Tagger - #7193
smith113-p wants to merge 2 commits into
Conversation
Gykes
left a comment
There was a problem hiding this comment.
Just a quick static check. No actual testing was done.
| alt="" | ||
| className="align-self-center scene-image" | ||
| /> | ||
| <div className="scene-image-overlay-container"> |
There was a problem hiding this comment.
This is nested inside the cover image. If there is no cover image will it return nothing? Is that expected?
There was a problem hiding this comment.
Yeah I would say this is expected. If we have no image we would need a different kind of UI. I'm not immediately sure what that UI would look like, and it is rare to not have an image (rare on TPDB, almost never happens on stashdb), so it is probably not worth the code complexity.
| <div className="scene-image-overlay-container"> | ||
| <img | ||
| src={scene.image} | ||
| alt="" | ||
| className="align-self-center scene-image" | ||
| /> | ||
| {scene.duration ? ( | ||
| <div className="scene-specs-overlay"> | ||
| <span className="overlay-duration"> |
There was a problem hiding this comment.
The "" branch would render and empty text node rather than nothing. I think returning null or just using && is a better way to do this.
Something like so:
{scene.duration && (
<div className="scene-specs-overlay">
<span className="overlay-duration">
{TextUtils.secondsToTimestamp(scene.duration)}
</span>
</div>
)}
There was a problem hiding this comment.
Done. I copied this from
...
smith113-p
left a comment
There was a problem hiding this comment.
sorry for the delay, see responses below
| <div className="scene-image-overlay-container"> | ||
| <img | ||
| src={scene.image} | ||
| alt="" | ||
| className="align-self-center scene-image" | ||
| /> | ||
| {scene.duration ? ( | ||
| <div className="scene-specs-overlay"> | ||
| <span className="overlay-duration"> |
There was a problem hiding this comment.
Done. I copied this from
...| alt="" | ||
| className="align-self-center scene-image" | ||
| /> | ||
| <div className="scene-image-overlay-container"> |
There was a problem hiding this comment.
Yeah I would say this is expected. If we have no image we would need a different kind of UI. I'm not immediately sure what that UI would look like, and it is rare to not have an image (rare on TPDB, almost never happens on stashdb), so it is probably not worth the code complexity.


Description
In scene tagger, if the stash box provided a duration, shows it on top of the scene image similar to how the local scene duration is displayed.
This is especially useful if the remote has a duration but no fingerprints (this can frequently happen with TPDB). Even when there are fingerprints, it can be useful to easily see exactly how the local duration differs from the remote duration.
Related Issue
Fixes #7201 (this was also a secondary request in #4482)
Testing
Manually scraped scenes with and without duration
Screenshots
Before:

After:

Checklist
AI Usage Disclosure
I used Codex/ChatGPT to write some of this code, especially the CSS. I did read and understand every line of the PR, though.
Additional Context