Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#8190 closed enhancement (duplicate)

"in" or "within" attribute

Reported by: displague Owned by:
Priority: minor Milestone: 1.9.0
Component: ui.position Version: 1.8.18
Keywords: Cc:
Blocked by: Blocking:

Description

JQuery UI positions could be enhanced with an "in" or "within" attribute.

This attribute would augment the existing keywords to allow positioning to a specific item (my) within a container (within).

The typical windowed slider could easily be positioned as

<div id="window">
  <ul id="slider">
    <li>Item 1</li>
    <li class="selected">Item 2</li>
    <li>Item 3</li>
  </ul>
</div>

<script>
$('#slider .selected').position({
  my:'center top',
  at:'center top',
  of: $('#window'),
  within: $('#slider')
})
</script>

Change History (2)

comment:1 Changed 7 years ago by Scott González

Resolution: duplicate
Status: newclosed

This has existed in master for 8 months.

comment:2 Changed 7 years ago by Scott González

Duplicate of #5645.

Note: See TracTickets for help on using tickets.