可调整大小也仅在一个方向上调整大小

发布于 2024-08-05 23:31:11 字数 195 浏览 1 评论 0原文

我正在尝试使用 jQuery UI 可调整大小功能。我想 仅在一个对象上添加南/西调整大小处理程序,因此它将调整大小 向西和向南。当它调整大小时,我想同时 调整另一个对象的大小,但仅限于“南”方向。我正在努力 使用alsoresize属性,但似乎总是调整第二个的大小 物体在两个方向上的移动量相同。有谁知道如何 达到这个目的?

谢谢你,

埃里克

I am trying to use the jQuery UI Resizable feature. I would like to
only add a south/west resize handler on one object, so it will resize
to the west and south. When it resizes, I would like to simultaneously
resize another object, but only in the 'south' direction. I am trying
to use the alsoresize property, but it seems always resizes the second
object by the same amount in both directions. Does any one know how to
achieve this?

Thank you,

Eric

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

烟酒忠诚 2024-08-12 23:31:11

试试这个埃里克家伙!边距/填充可能存在一些问题。

$('.main').resizable({
    resize: function(event, ui)
    {
        $('.also').css("width",ui.size.width+"px");
    }
});

Try this fellow Eric! There might be some issues with margin/padding.

$('.main').resizable({
    resize: function(event, ui)
    {
        $('.also').css("width",ui.size.width+"px");
    }
});
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文