pace icon indicating copy to clipboard operation
pace copied to clipboard

Setting any value to the "left" property of "pace-progress" class reverses the bar load animation

Open gabrielrainha opened this issue 11 years ago • 2 comments

I need to set some left margin to the loading bar, so that it starts where my static left menu ends. I'm using the "minimal" theme. I've tested the same setup with version 0.5.1 and it works fine. The issue was observed on versions 1.0.0 and onward. The bar starts fully loaded and retracts from left to right.

Here is the 1.0.0 fiddle: https://jsfiddle.net/z8hajad5/ And the 0.5.1 working fiddle: https://jsfiddle.net/mdgkjLah/ As jsfiddle complained about adding the .js file as an external resource, I had to copy it to the javascript section, so it's a bit messy. The code does not matter on this case, though.

gabrielrainha avatar Mar 26 '15 21:03 gabrielrainha

I'm seeing the same behaviour. Did you make any progress on this, @gabrielrainha?

jakeorr avatar May 27 '15 18:05 jakeorr

Thanks for the clear report and fiddles. Since 1.0, the bar is parked off-screen with right: 100% and slid in with a transform, so adding left makes it start fully visible and slide away. To offset it, make .pace a clipped strip that starts after your menu:

.pace {
  position: fixed;
  top: 0;
  left: 250px;   /* your menu width */
  right: 0;
  height: 2px;   /* the bar height */
  overflow: hidden;
  z-index: 2000;
  transform: translateZ(0); /* lets the bar be positioned and clipped inside this strip */
}

If that doesn't work on the latest version, comment here and we'll take another look.

CodeByZach avatar Nov 02 '26 01:11 CodeByZach