-
-
Notifications
You must be signed in to change notification settings - Fork 277
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Process loaded code when expanding diff views #453
Comments
This sounds related to #416, since they both concern page changes that don't trigger reprocessing. |
I'm not sure that's entirely related, as your linked issue concerns navigation (pjax), while this changes the page state without navigation. |
I agree with @xPaw. This issue is slightly different. It should be relative easy to fix. We're happy to provide mentor help for people who want to pick this up. |
Hey @stefanbuck, any pointers for this one? |
At its core, it's just about calling OctoLinker/packages/core/octo-linker.js Line 20 in e218001
|
@stefanbuck I have a preliminary version working with MutationObserver, I am looking for addedNodes that contains |
Great news 👍 Yes, putting that into |
<!-- Thanks for filing a pull request! Please look at the following checklist to ensure that your PR can be accepted quickly: --> This is a possible implementation for #453, we observe the DOM, if any new `.blob-expanded` nodes are added, then the extension is rerun. As far as testing goes, I will wait for feedback, I added a single test that clickes the specific `.js-expand` element and then tries to process a single line from it. ### Checklist: - [ ] If this PR is a new feature, please provide at least one example link - [x] Make sure all of the significant new logic is covered by tests
Link: https://github.com/thelounge/thelounge/pull/1839/files#diff-cf27c1d543e886c89cd9ac8b8aeaf05b
Hopefully the GIF explains what I mean:
![03-161708105](https://user-images.githubusercontent.com/613331/36936512-3e3688fe-1f0f-11e8-8428-9bf3f13d3a06.gif)
The text was updated successfully, but these errors were encountered: