- 授权协议: Apache
- 开发语言: JavaScript
- 操作系统: 跨平台
- 软件首页: http://sun.faysunshine.com/layui/formSelects-v4/example/example_v4.html
- 软件文档: http://sun.faysunshine.com/layui/formSelects-v4/example/example_v4.html
软件介绍
formSelects-v4.js 基于Layui的多选解决方案
使用方式
//1.下载formSelects-v4.1
//2.模块化使用
<script src="layui.js" type="text/javascript" charset="utf-8"></script>
<script type="text/javascript">
//全局定义一次, 加载formSelects
layui.config({
base: '../src/' //此处路径请自行处理, 可以使用绝对路径
}).extend({
formSelects: 'formSelects-v4'
});
//加载模块
layui.use(['formSelects'], function(){
var formSelects = layui.formSelects;
});
</script>
//3.非模块化使用
<script src="layui.all.js" type="text/javascript" charset="utf-8"></script>
<script src="formSelects-v4.js" type="text/javascript" charset="utf-8"></script>
<script type="text/javascript">
var formSelects = layui.formSelects;
</script>基本参数
| 属性名 | 说明 | 示例 |
|---|---|---|
| xm-select | 多选核心, 标记不同的多选, 多选ID | xm-select="id" |
| xm-select-max | 多选最多选择数量 | xm-select-max="3" |
| xm-select-skin | 皮肤 | xm-select-skin=" default | primary | normal | warm | danger " |
| xm-select-search | 本地搜索 & 远程搜索 | xm-select-search, xm-select-search="/search", 值为空时已有条目过滤搜索, 有值时开启远程搜索 |
| xm-select-create | 条目不存在时创建, 标记性属性 | xm-select-create |
| xm-select-direction | 下拉方向 | xm-select-direction="auto|up|down", 自动, 上, 下, 默认自动模式 |
| xm-select-height | 标记select高度是否固定 | xm-select-height="36px", 高度不再随数据变化而变化 |
| xm-select-radio | 单选模式 | xm-select-radio, 最多只能选择一个 |
| xm-select-search-type | 搜索框的显示位置 | xm-select-search-type="title" 在下拉选title部分显示, xm-select-search-type="dl" 在选项的第二条显示 |
| xm-select-show-count | 多选显示的label数量 | xm-select-show-count="2", 超出后隐藏 |
效果图
Programming the Mobile Web
Maximiliano Firtman / O'Reilly Media / 2010-07-23 / $44.99
* Learn how to use your existing skills to move into mobile web development * Discover the new possibilities of mobile web development, and understand its limitations * Get detailed coverage of ......一起来看看 《Programming the Mobile Web》 这本书的介绍吧!
