Welcome to TalkGraphics.com
Results 1 to 7 of 7
  1. #1
    Join Date
    May 2014
    Posts
    6

    Default Scroll and Stick

    I understand how to make an object sticky. However, I noticed that the Xara site: http://www.xara.com/us/web-designer/features/ displays an full-width image and nav bar that starts out below the top of screen and "sticks" to top after you start scrolling down.

    Anyone know how to replicate this?

  2. #2
    Join Date
    Apr 2012
    Location
    SW England
    Posts
    17,842

    Default Re: Scroll and Stick

    Probably with a cheat.
    Make a sticky object on a Reveal event appear in the same place as the bar that's just been scrolled up into position.
    If it is not a Xara-driven event then there will be some other CSS set off by a JavaScript trigger to do the same.

    Acorn
    Acorn - installed Xara software: Cloud+/Pro+ and most others back through time (to CC's Artworks). Contact for technical remediation/consultancy for your web designs.
    When we provide assistance, your responses are valuable as they benefit the community. TG Nuggets you might like. Report faults: Xara Cloud+/Pro+/Magix Legacy; Xara KB & Chat

  3. #3
    Join Date
    Aug 2000
    Location
    Placitas, New Mexico, USA
    Posts
    41,509

    Default Re: Scroll and Stick

    If Xara gets around to a Conceal feature, which I hope they do soon, then a whole lot more things will be possible.

  4. #4
    Join Date
    May 2014
    Posts
    6

    Default Re: Scroll and Stick

    Thanks Acorn! Good idea for a "cheat".

    However, the Reveal event is triggered when the "object comes into view" OR until another object comes into view.

    Since I'm trying to make the object stick (or appear to stick) after moving the headline moves off of the screen, I can't see an opportunity to trigger the Reveal with an object coming into view.

    Perhaps this is another opportunity for you to build some of your legendary CSS magic we can insert into a placeholder

    In the meantime, I'll wait with Gary for a new "Conceal" feature.

    Thanks!

  5. #5
    Join Date
    Apr 2012
    Location
    SW England
    Posts
    17,842

    Default Re: Scroll and Stick

    Quote Originally Posted by dportener View Post
    Thanks Acorn!
    Perhaps this is another opportunity for you to build some of your legendary CSS magic we can insert into a placeholder
    It seems to be quite complicated at first.
    I have found this: http://jsfiddle.net/livibetter/HV9HM/.

    basically, it boils down to being able to detect a scroll event; you would use jQuery or Javascript for this.
    The jQuery toggles a class of an object to become fixed when a position is crossed and toggled back when it is smaller.

    In a Xara design it should only need to have an object with an ID that is then toggled by such an event and the necessary CSS is applied against the toggled class.

    Acorn
    Acorn - installed Xara software: Cloud+/Pro+ and most others back through time (to CC's Artworks). Contact for technical remediation/consultancy for your web designs.
    When we provide assistance, your responses are valuable as they benefit the community. TG Nuggets you might like. Report faults: Xara Cloud+/Pro+/Magix Legacy; Xara KB & Chat

  6. #6
    Join Date
    May 2014
    Posts
    6

    Default Re: Scroll and Stick

    Thanks Acorn!

    I'll try to make this work - and will post if successful.

  7. #7
    Join Date
    Aug 2000
    Location
    Harwich, Essex, England
    Posts
    21,924

    Default Re: Scroll and Stick

    .... displays an full-width image and nav bar that starts out below the top of screen and "sticks" to top after you start scrolling down.

    Anyone know how to replicate this?
    My question is why would you want to do this? It's ugly in my opinion and just confuses the page display. Have a sticky navbar by all means but don't have it jump up and down the screen dependant on the scrolling, just have it stick to the top of the page. Appears to me it's one of these "Just because you can do it, do you really have to do it?" type of effects.
    Egg

    Intel i7 - 4790K Quad Core + 16 GB Ram + NVIDIA Geforce GTX 1660 Graphics Card + MSI Optix Mag321 Curv monitor
    + Samsung 970 EVO Plus 500GB SSD + 232 GB SSD + 250 GB SSD portable drive + ISP = BT + Web Hosting = TSO Host

 

 

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •