Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Dawid 26 posts 136 karma points c-trib
    Apr 24, 2017 @ 13:11
    Dawid
    0

    [Grid] Render navigation base on selected grid elements

    Hello,

    I've following requirements:

    • Home page contains Grid with few elements.
    • Home page will be the only Page on the website (One page website ?).
    • Navigation on the header should contain links to some of the elements in the Grid
    • After clicking on the navigation item, site should scroll to the top of appropriate Grid element.

    My current solution to this requirements is

    • Add extra property Navigation Title to each of the Grid Editors.
    • I'm using Leblender Editor as Grid Editor
    • If the Navigation Title will be filled then this grid element will qualify to be displayed in the navigation.
    • To get all the grid elements to render I will
      • use the GetPropert(gridAlias) to get the grid
      • Iterate over sections , rows and also areas properties of the Grid Element.
      • If there is a Navigation Title property in value collection and it contains any value, then I will use it to render this in navigation
    • To be able to scroll to given grid element:
      • Add id attribute to the grid elements that have Navigation Title filled in.

    Is this solution correct or maybe some of you have better idea how I can solve this problem?

    Best regards, Dawid

Please Sign in or register to post replies

Write your reply to:

Draft