jQuery UI and Splitter

前端 未结 4 1404
栀梦
栀梦 2021-02-08 13:45

Using jQuery UI, how can I use a Splitter kind of feature like the one at http://methvin.com/splitter/3csplitter.html?

I am asking this as I need 2 things to be impleme

4条回答
  •  有刺的猬
    2021-02-08 14:20

    I used Dmitriy's answer as the base of my implementation. Note that there is nothing stopping that particular implementation from doubling the bounding box when the slider is dragged to the right.

    I needed a simple non-moveable splitter for now (with the view to making the panes resizable in the future), and my application is already using jQuery, so I achieved this by changing part of his code as follows:

    $(function () 
    {
        $(".resizable1").resizable(
        {
            autoHide: false,
            containment: "#wrap",
            ...
    

    I also changed the css cursor style (among other things) to prevent the resizable cursor from being displayed as follows:

    .ui-resizable-e { 
        cursor: default; 
        ...
    

    Thanks Dmitriy!

提交回复
热议问题