Spotify 标准化曲目列表设置滚动条出现前的高度
使用如下代码片段:
sp = getSpotifyApi(1);
var models = sp.require("sp://import/scripts/api/models");
var tpl = new models.Playlist();
var tempList = new views.List(tpl);
$(tempList.node).appendTo(document.getElementById("tracks"));
如这篇文章,如何更改使用提供的 Spotify 模型显示曲目的默认 大小?
我希望能够对其进行设置,以便在元素的大小为 300px 而不是默认的 600px 时出现滚动条。
看看这个API,没有'这似乎是一个简单的方法。
Using a code snippet like:
sp = getSpotifyApi(1);
var models = sp.require("sp://import/scripts/api/models");
var tpl = new models.Playlist();
var tempList = new views.List(tpl);
$(tempList.node).appendTo(document.getElementById("tracks"));
As described in this post, how can I change the default <div>
size that the tracks are displayed in using the supplied Spotify model?
I want to be able to set it so that a scrollbar will appear if the size of the element is say 300px instead of the default 600px.
Looking at this API, there doesn't appear to be a simple way to do this.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可以使用 css 设置 max-height 属性。
You can set the max-height property with css.