Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.
… split screen Spy on one side and thread opens on the right …

When I first read that, I thought of Shrook :)

2015-07-08 12-32-55 screenshot.png
 
There's a new version that make it look more iOS'y. Also, clicking anywhere in the thread row opens it up. Clicking on the links inside the row such as the user or subforum still opens them up as normal as well.
 
  • Like
Reactions: grahamperrin
Are you still running it from your custom extension for Safari? If you can share it with me, I can gave a look for you. Also, if you look at your console to see if any errors are there.
Yes, all it does is inject the script into the page as plain JavaScript. There is this one error:
Code:
[Error] ReferenceError: Can't find variable: $
    _runSuperMod (spy, line 88)
    global code (spy, line 145)
    appendChild ([native code], line 0)
    global code (Spy.js, line 246)
    close ([native code], line 0)
    Gb (jquery.min.js, line 3)
    Wb (jquery.min.js, line 3)
    show (jquery.min.js, line 4)
    (anonymous function) (jquery.min.js, line 4)
    jc (jquery.min.js, line 4)
    lc (jquery.min.js, line 4)
    g (jquery.min.js, line 4)
    dequeue (jquery.min.js, line 3)
    (anonymous function) (jquery.min.js, line 3)
    each (jquery.min.js, line 2)
    each (jquery.min.js, line 2)
    queue (jquery.min.js, line 3)
    animate (jquery.min.js, line 4)
    (anonymous function) (jquery.min.js, line 4)
    (anonymous function) (xenforo.js, line 55)
    load (xenforo.js, line 52)
    b (xenforo.js, line 269)
    ajaxStart (xenforo.js, line 270)
    dispatch (jquery.min.js, line 3)
    handle (jquery.min.js, line 3)
    trigger (jquery.min.js, line 3)
    trigger (xenforo.js, line 2)
    ajax (jquery.min.js, line 4)
    getSpyItems (spy.js, line 1)
Again, the page is completely blank, no visible content whatsoever.

Switching back to your other script it still works just fine.
 
Yes, all it does is inject the script into the page as plain JavaScript. There is this one error:
Code:
[Error] ReferenceError: Can't find variable: $
    _runSuperMod (spy, line 88)
Again, the page is completely blank, no visible content whatsoever.

Switching back to your other script it still works just fine.

It looks like your extension is adding the script as soon as the page starts to load, such that jQuery isn't even ready yet. If you have the option to add the script to the end of the document or body that might help.
 
It looks like your extension is adding the script as soon as the page starts to load, such that jQuery isn't even ready yet. If you have the option to add the script to the end of the document or body that might help.
If this is the case, wouldn't your other script fail to work as well?
 
If this is the case, wouldn't your other script fail to work as well?

You're right. It's strange that one works while the other fails. That particular error basically means that jQuery hasn't loaded or else the script is being run in the wrong scope.

I'm having the same issue... just stumbled on this thread and I'm working my way through it
First script works well
Second gives me a blank, even with first disabled or uninstalled

Lemme check this out. Just on my way into work right now so have a computer to debug with.
 
  • Like
Reactions: grahamperrin
I'm having the same issue... just stumbled on this thread and I'm working my way through it
First script works well
Second gives me a blank, even with first disabled or uninstalled

Would you be able to have the web developer console open (refresh after opening) with the non-working script and see what errors you have? If you're using something like Tampermonkey, it should only inject the script well after the jQuery ($) script has been loaded. I suspect it's a different issue to redheelers.
 
  • Like
Reactions: grahamperrin
Would you be able to have the web developer console open (refresh after opening) with the non-working script and see what errors you have? If you're using something like Tampermonkey, it should only inject the script well after the jQuery ($) script has been loaded. I suspect it's a different issue to redheelers.

I'm actually happy with the script that is running since I can filter the PRSI out
Not even sure what advantage the other script would give me, so I don't know what I'm missing :)

I followed your instructions and installed Tampermonkey and the 2 scripts (only 1 enabled at a time)
I even uninstalled to only have the 1 script and no joy
I have them both installed now with only the first one enabled and running
 
I declare that bug fixed. Everyone on Safari 8 can now enjoy the split view mod now. *grumbles something about vendor specific CSS extensions*

I have the public beta of Safari 9 on the machine I was developing this with and it, well, worked on it. I had to dig up my old 2011 MBP to test it on.

@MacDawg Split-view is all the rage. If you're a pro forum surfer, you should give it a go.
 
  • Like
Reactions: grahamperrin
I declare that bug fixed. Everyone on Safari 8 can now enjoy the split view mod now. *grumbles something about vendor specific CSS extensions*

I have the public beta of Safari 9 on the machine I was developing this with and it, well, worked on it. I had to dig up my old 2011 MBP to test it on.

@MacDawg Split-view is all the rage. If you're a pro forum surfer, you should give it a go.

Got it!
Great work and thanks!
Greatly appreciated!

Pretty cool stuff :)
 
I declare that bug fixed. Everyone on Safari 8 can now enjoy the split view mod now. *grumbles something about vendor specific CSS extensions*

I have the public beta of Safari 9 on the machine I was developing this with and it, well, worked on it. I had to dig up my old 2011 MBP to test it on.

@MacDawg Split-view is all the rage. If you're a pro forum surfer, you should give it a go.
Is there a way to keep the main header of the forum visible, and useable with this?

I'm on Firefox with Windows 8.1 right now and I use the links in the main header a lot.
Capture.PNG


Instead this is all I see.

Capture1.PNG


BTW, great work on this, it's really cool.
 
  • Like
Reactions: grahamperrin
Done.

If the screenshot looks confusing, let me explain: the header links are opening in the 'detail view' as well. I opened Spy from the header and it opens a Spy in a Spy. Simple.
 

Attachments

  • done.png
    done.png
    273.9 KB · Views: 223
Done.

If the screenshot looks confusing, let me explain: the header links are opening in the 'detail view' as well. I opened Spy from the header and it opens a Spy in a Spy. Simple.
This is fantastic! I really love what you did with it. :)
 
Done.

If the screenshot looks confusing, let me explain: the header links are opening in the 'detail view' as well. I opened Spy from the header and it opens a Spy in a Spy. Simple.
Hate to bug you with too much but is it possible to implement two other things?
  1. Create a button on a thread listing in Spy that takes you to the first post of the thread? That was a feature on VB.
  2. When clicking on a thread from the Spy and opening it up in the split view, it shows the thread title in your drop-down bar. But when I go to my Watched Threads, from the header bar you just added, and click on a thread from there, it opens in the split view window, as expected, but the title bar still shows "Watched Threads" instead of the thread title. Can that be adjusted?
 
  • Like
Reactions: grahamperrin
Quite a bit of attention.

Hate to bug you with too much but is it possible to implement two other things?
  1. Create a button on a thread listing in Spy that takes you to the first post of the thread? That was a feature on VB.
  2. When clicking on a thread from the Spy and opening it up in the split view, it shows the thread title in your drop-down bar. But when I go to my Watched Threads, from the header bar you just added, and click on a thread from there, it opens in the split view window, as expected, but the title bar still shows "Watched Threads" instead of the thread title. Can that be adjusted?

Not bad suggestions. I wouldn't mind adding in a few.
1. Aim to reduce the spacing per Spy thread. I can only fit 5-7 posts (depending on what machine and screen size I am using). I would rather have 20 Spy replies and lose what user replied, or lose a summary of the individual post.
2. If you focus out of the Spy tab, when you come back new posts are bold or highlighted in some way to show you what you have missed out on.
3. Your replies should appear a different colour EDIT: is that what the little green dot is?
4. Reload/refresh button on the individual thread that you're looking at. Force reloading the entire page loses your "My Threads" drop down info.

That's all for now.
 
Last edited:
  • Like
Reactions: grahamperrin
Hate to bug you with too much but is it possible to implement two other things?
  1. Create a button on a thread listing in Spy that takes you to the first post of the thread? That was a feature on VB.
  2. When clicking on a thread from the Spy and opening it up in the split view, it shows the thread title in your drop-down bar. But when I go to my Watched Threads, from the header bar you just added, and click on a thread from there, it opens in the split view window, as expected, but the title bar still shows "Watched Threads" instead of the thread title. Can that be adjusted?

Number one I've decided against because of the way the URL to the post is presented. Each of the links is to a URL of format /post/postId and not thread?postId like it was on VB (where I could easily strip out the ?postId to send you on your way). To do the same now (assuming an API isn't available for it, and I can't find it for Xenforo) I will have to load up the entire thread first (just the HTML) and grab the redirected URL and only then open it up in the frame. It's tens of KB to load that dummy page, and I haven't found a way to not load the contents, and not to mention it adds latency.

See next post for #2
 
New split view: https://github.com/sammich/macrumors-spy-mod/raw/master/split.user.js (clicking on the link will ask for the update/install to occur).

There's a new version with some experimental changes as well as some hopefully useful ones:
  • removed the secondary navbar. You can bring it up by hovering over the main navbar for a moment
  • added a refresh button to the right
  • opening a link will modify your location bar so you can grab the url if you want to from there
  • pressing back in your browser will actually go back in your spy browsing history (although it's a little buggy)
  • turned off snippet line wrapping

Not bad suggestions; I wouldn't mind adding in a few.
1. Aim to reduce the spacing per Spy thread. I can only fit 5-7 posts (depending on what machine and screen size I am using). I would rather have 20 Spy replies and lose what user replied, or lose a summary of the individual post.
2. If you focus out of the Spy tab, when you come back new posts are bold or highlighted in some way to show you what you have missed out on.
3. Your replies should appear a different colour EDIT: is that what the little green dot is?
4. Reload/refresh button on the individual thread that you're looking at. Force reloading the entire page loses your "My Threads" drop down info.

That's all for now.
  1. Done
  2. I'll put it on backlog.
  3. Your replies are green...the little green dot is for a post you've opened
  4. Done
 
Last edited:
There's a new version with some experimental changes as well as some hopefully useful ones:
Great - Will users need a summary of how to update? Or do we simply go to the first post and click on that version?

  1. Your replies are green...the little green dot is for a post you've opened
I mean on the left hand bar, if I reply to a post I can see my username and whatnot, but no indication that it's me (apart from my username). Picture to follow.

Edit: Please see picture: There is not much of an indicator that I replied.
 

Attachments

  • Reply.PNG
    Reply.PNG
    53.1 KB · Views: 197
New split view: https://github.com/sammich/macrumors-spy-mod/raw/master/split.user.js (clicking on the link will ask for the update/install to occur).
I just updated to this version and lost the bottom half of the main forum menu bar. (right now I'm on Safari with Yosemite)

Also, I noticed yesterday (on Firefox for Windows 8.1), that new alerts wouldn't show up in the little flag and I had to get out of the custom Spy screen to a normal MR page to get to the alerts.

Screen Shot 2015-07-10 at 6.54.58 AM.png
 
I just updated to this version and lost the bottom half of the main forum menu bar. (right now I'm on Safari with Yosemite)

Also, I noticed yesterday (on Firefox for Windows 8.1), that new alerts wouldn't show up in the little flag and I had to get out of the custom Spy screen to a normal MR page to get to the alerts.
He only develops for Chrome and doesn't care about us Safari/FireFox users :p
 
I just updated to this version and lost the bottom half of the main forum menu bar. (right now I'm on Safari with Yosemite)

Also, I noticed yesterday (on Firefox for Windows 8.1), that new alerts wouldn't show up in the little flag and I had to get out of the custom Spy screen to a normal MR page to get to the alerts.

It's in my release notes post - I've hidden it by default and you can show it again by hovering over the main navbar.
 
  • Like
Reactions: grahamperrin
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.