Problem/Motivation
The threads are always outputed inside a div with an ID like private-message-thread-<n>.
Here is the code:
https://git.drupalcode.org/project/private_message/-/blob/3.0.2/src/Enti...
A common usage of Private Message is to display a thread with the Inbox in a side bar. In this case, the HTML page will have two divs with the same ID, which is not correct.
Steps to reproduce
Display the Inbox block in a side bar, create a thread and check the HTML of the thread's page.
Proposed resolution
My proposal is to remove the ID of the thread when it's not the full view (meaning, the threads in Inbox won't have it).
AFAIK we are using the attribute "data-thread-id" for any JS manipulation, so I don't think this will have any impact.
Issue fork private_message-3484828
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
sourabhsisodia_ commentedComment #4
sourabhsisodia_ commentedComment #5
claudiu.cristeaIt seems that the MR is breaking the tests (or even JS functionality?)
Comment #7
alorencComment #8
claudiu.cristeaThank you for reporting and fixing.
Comment #9
herved commented+1, looks ok to me
Maybe the scope of #3488097: Remove private-message-* id could have been combined here, but it's fine either way.
Comment #11
claudiu.cristeaThanks!