Unpoly can apply temporary status effects to your page as the user navigates through your site.
For example, you can show arbitrary loading state while waiting for the server, implement optimistic rendering or highlight current links in navigation bars.
Marks this element as a navigational container, such as a menu or navigation bar.
When a link within a navigational container points to the current location, it is assigned the .up-current
class.
While rendering, the .up-active
class is added to the origin element that triggered the change.
While rendering, all targeted fragments are assigned the .up-loading
class.
Links or forms can define a placeholder that will be shown within the targeted fragment while loading content from the server.
Links or forms can name a preview function that is called while loading content from the server.
While rendering, the .up-active
class is added to the origin element that triggered the change.
Links within navigational container
may use the [up-alias]
attribute to alternative URLs for which they
should also be highlighted as .up-current
.
When a link within a navigational container points to the current location, it is assigned the .up-current
class.
While rendering, all targeted fragments are assigned the .up-loading
class.
Marks this element as a navigational container, such as a menu or navigation bar.
Links or forms can define a placeholder that will be shown within the targeted fragment while loading content from the server.
Links or forms can name a preview function that is called while loading content from the server.
Registers a named preview function.
Sets default options for this package.