Switch to full style
Discussion for the unofficial, community-developed addons, extensions and scripts built for the Waze Map Editor.

The official index of these tools is the Community Plugins, Extensions and Tools wiki page.

Forum rules

Discussion for the unofficial, community-developed addons, extensions and scripts built for the Waze Map Editor.

DO NOT START a new thread unless it is about a new idea. Keep discussion of existing tools within the main thread for that tool.

The official index of these tools is the Community Plugins, Extensions and Tools wiki page.
Post a reply

Re: [Script] WME Street View Availability (0.8.0)

Tue Aug 20, 2019 11:08 pm

Glodenox wrote:The script now restores the last used width of the Street View panorama

Hey there. I'm having a little problem with this latest feature - or at least how it interacts with a new feature in WME FixUI. It seems we've both been working on the same problem from different angles! :lol:

The problem is really down to bad design by the WME Devs. As initially loaded, the relative widths of the map and GSV panels are controlled by CSS classes setting the widths to 50%/50%. But, as soon as you drag the handle, WME adds inline CSS to the elements themselves setting width/drag handle positions in fixed pixel values.

My script will alter the default % values in the CSS classes to change the default split position. If you drag the handle, that position gets overridden by the dragged-to position set in the inline CSS.

It looks like you are restoring the previous position by storing the inline CSS values and restoring them on reload - but you are doing this even if the handle hasn't been dragged and is therefore still at the default position and controlled by the CSS classes.

That's where it's interfering with WME FixUI. I think your script is looking for the inline CSS, not seeing any, then assuming the position is at 50% and setting/storing the corresponding inline CSS settings - even though FixUI has altered that default.

Perhaps you could change your code to not store/set a permission if no inline CSS setting is found? Or maybe look at the % position set in on these 3 CSS classes:
  • #editor-container #map.street-view-mode #waze-map-container {width}
  • #editor-container #map.street-view-mode #street-view-drag-handle {left}
  • #editor-container #map.street-view-mode #street-view-container {width}

Re: [Script] WME Street View Availability (0.8.0)

Wed Aug 21, 2019 1:06 am

I haven't got FixUI running at the moment, I'll do some testing tomorrow to make sure that what I'm saying below is actually right.

The script should not adjust the size if it was never dragged (the trigger is an adjustment to the style attribute where the width is set to something other than the empty string), so FixUI's new default should still work as long as the user never adjusted it themselves. The idea of the feature in this userscript is exactly to make any adjustment by the user the new default from then on, so I don't think it's possible to make this function somehow work together with the FixUI default any further than that.

The only thing I can do is provide an option to disable this feature in the settings tab. That way people can decide for themselves whether they want to always have the width restored each time they open the Street View panorama. Because right now people are simply forced to accept this feature if they install this script, which admittedly isn't ideal. I was already thinking about doing something like that, but I just wanted to get the feature out of the door already.

Re: [Script] WME Street View Availability (0.8.0)

Thu Sep 26, 2019 10:43 am

After the WME update this week, roads with available SV are not lighting up blue.

Re: [Script] WME Street View Availability (0.8.1)

Thu Sep 26, 2019 4:10 pm

Version 0.8.1 has just been released to fix the issue with the new layer menu breaking the script. I still need to work on adding a toggle to choose whether to save the Street View window width though.

Re: [Script] WME Street View Availability (0.8.1)

Fri Nov 15, 2019 5:31 pm

Hey there! Just started noticing an issue today where having the script on, and placing the SV pin to see SV, turns the screen white and I have to refresh to fix. Something seems to have broken the script.

Re: [Script] WME Street View Availability (0.8.1)

Fri Nov 15, 2019 9:54 pm

I'm afraid I'm not seeing the same issue appear. Which browser do you use and on which version of the WME (beta/prod)?

The only thing I can imagine is that the sidescreen for the Street View is taking up the full width of the screen. That could maybe the case for you? Do you see a handle if you hover over the left side of that window?

Re: [Script] WME Street View Availability (0.8.1)

Fri Nov 15, 2019 9:59 pm

Hey thanks for the quick response. WME version is prod and I'm using Chrome 78.0.3904.97 (Official Build) (64-bit). And now that I'm testing your theory of the side screen taking the full width, I'm actually finding the opposite and realizing what caused this. I have 2 large screens (extended monitor setup), and extended my Chrome window super-wide earlier this morning. I had SV open on the side. Once you resize the Chrome window to the left of the SV side screen edge, it turns the whole screen white. Nevertheless, I figured out the issue. Thanks!
Post a reply