1 В избранное 0 Ответвления 0

OSCHINA-MIRROR/pjy-jquery-plugin

Присоединиться к Gitlife
Откройте для себя и примите участие в публичных проектах с открытым исходным кодом с участием более 10 миллионов разработчиков. Приватные репозитории также полностью бесплатны :)
Присоединиться бесплатно
В этом репозитории не указан файл с открытой лицензией (LICENSE). При использовании обратитесь к конкретному описанию проекта и его зависимостям в коде.
Клонировать/Скачать
nicelabel.html 6 КБ
Копировать Редактировать Web IDE Исходные данные Просмотреть построчно История
pjy Отправлено 17.05.2016 05:11 a2ae0f9
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>test</title>
<link href="./nicelabel/css/jquery-nicelabel.css" rel="stylesheet" type="text/css" />
<script src="./nicelabel/js/jquery.min.js"></script>
<style>
.clearfix{clear:both;}
.rect-checkbox{float:left;margin-left:20px;}
.rect-radio{float:left;margin-left:20px;}
.circle-checkbox{float:left;margin-left:20px;}
.circle-radio{float:left;margin-left:20px;}
.text_checkbox{float:left;margin-left:20px;}
.text_radio{float:left;margin-left:20px;}
</style>
</head>
<body>
<div id="rect-checkbox">
<h2 style="margin-left:20px;">矩形滑块checkbox</h2>
<br>
<input class="rect-nicelabel" data-nicelabel='{"position_class": "rect-checkbox"}' checked type="checkbox" />
<input class="rect-nicelabel" data-nicelabel='{"position_class": "rect-checkbox"}' type="checkbox" />
<input class="rect-nicelabel" data-nicelabel='{"position_class": "rect-checkbox"}' disabled type="checkbox" />
<input class="rect-nicelabel" data-nicelabel='{"position_class": "rect-checkbox"}' type="checkbox" />
</div>
<div class="clearfix"></div>
<br>
<div id="rect-radio">
<h2 style="margin-left:20px;">矩形滑块radio</h2>
<br>
<input class="rect-nicelabel" data-nicelabel='{"position_class": "rect-radio"}' checked name="rect-radio" type="radio" />
<input class="rect-nicelabel" data-nicelabel='{"position_class": "rect-radio"}' name="rect-radio" type="radio" />
<input class="rect-nicelabel" data-nicelabel='{"position_class": "rect-radio"}' name="rect-radio" type="radio" />
<input class="rect-nicelabel" data-nicelabel='{"position_class": "rect-radio"}' disabled name="rect-radio" type="radio" />
</div>
<div class="clearfix"></div>
<br>
<div id="circle-checkbox">
<h2 style="margin-left:20px;">圆形滑块checkbox</h2>
<br>
<input class="circle-nicelabel" data-nicelabel='{"position_class": "circle-checkbox"}' disabled checked type="checkbox" />
<input class="circle-nicelabel" data-nicelabel='{"position_class": "circle-checkbox"}' type="checkbox" />
<input class="circle-nicelabel" data-nicelabel='{"position_class": "circle-checkbox"}' type="checkbox" />
<input class="circle-nicelabel" data-nicelabel='{"position_class": "circle-checkbox"}' type="checkbox" />
</div>
<div class="clearfix"></div>
<br>
<div id="circle-radio">
<h2 style="margin-left:20px;">圆形滑块radio</h2>
<br>
<input class="circle-nicelabel" data-nicelabel='{"position_class": "circle-radio"}' disabled checked name="circle-radio" type="radio" />
<input class="circle-nicelabel" data-nicelabel='{"position_class": "circle-radio"}' name="circle-radio" type="radio" />
<input class="circle-nicelabel" data-nicelabel='{"position_class": "circle-radio"}' name="circle-radio" type="radio" />
<input class="circle-nicelabel" data-nicelabel='{"position_class": "circle-radio"}' name="circle-radio" type="radio" />
</div>
<div class="clearfix"></div>
<br>
<div id="text-checkbox">
<h2 style="margin-left:20px;">文字按钮checkbox</h2>
<br>
<input class="text-nicelabel" data-nicelabel='{"position_class": "text_checkbox", "checked_text": "已选定", "unchecked_text": "前端工程师"}' checked type="checkbox" />
<input class="text-nicelabel" data-nicelabel='{"position_class": "text_checkbox", "checked_text": "已选定", "unchecked_text": "PHP工程师"}' type="checkbox" />
<input class="text-nicelabel" data-nicelabel='{"position_class": "text_checkbox", "checked_text": "已选定", "unchecked_text": "IOS工程师"}' type="checkbox" />
<input class="text-nicelabel" data-nicelabel='{"position_class": "text_checkbox"}' type="checkbox" />
</div>
<div class="clearfix"></div>
<br>
<div id="text-radio">
<h2 style="margin-left:20px;">文字按钮radio</h2>
<br>
<input class="text-nicelabel" data-nicelabel='{"position_class": "text_radio", "checked_text": "已选定", "unchecked_text": "前端工程师"}' checked type="radio" name="text_radio" />
<input class="text-nicelabel" data-nicelabel='{"position_class": "text_radio", "checked_text": "已选定", "unchecked_text": "PHP工程师"}' type="radio" name="text_radio" />
<input class="text-nicelabel" data-nicelabel='{"position_class": "text_radio", "checked_text": "已选定", "unchecked_text": "IOS工程师"}' type="radio" name="text_radio" />
<input class="text-nicelabel" data-nicelabel='{"position_class": "text_radio"}' type="radio" name="text_radio" />
</div>
<div class="clearfix"></div>
<br>
<div id="text-checkbox-ico">
<h2 style="margin-left:20px;">自定义图标文字按钮</h2>
<br>
<input class="text-nicelabel" data-nicelabel='{"position_class": "text_checkbox", "checked_text": "已选定", "unchecked_text": "前端工程师"}' checked type="checkbox" />
<input class="text-nicelabel" data-nicelabel='{"position_class": "text_checkbox", "checked_text": "已选定", "unchecked_text": "PHP工程师"}' type="checkbox" />
<input class="text-nicelabel" data-nicelabel='{"position_class": "text_checkbox", "checked_text": "已选定", "unchecked_text": "IOS工程师"}' type="checkbox" />
<input class="text-nicelabel" data-nicelabel='{"position_class": "text_checkbox"}' type="checkbox" disabled />
</div>
</body>
<script src="./nicelabel/js/jquery.nicelabel.js"></script>
<script>
$(function(){
$('#rect-checkbox > input').nicelabel();
$('#rect-radio > input').nicelabel();
$('#circle-checkbox > input').nicelabel();
$('#circle-radio > input').nicelabel();
$('#text-checkbox > input').nicelabel();
$('#text-radio > input').nicelabel();
$('#text-checkbox-ico > input:eq(0)').nicelabel({
checked_ico: './ico/checked.png',
unchecked_ico: './ico/unchecked.png'
});
$('#text-checkbox-ico > input:eq(1)').nicelabel({
checked_ico: './ico/checked.png',
unchecked_ico: './ico/unchecked.png'
});
$('#text-checkbox-ico > input:eq(2)').nicelabel({
checked_ico: './ico/checked.png',
unchecked_ico: './ico/unchecked.png'
});
$('#text-checkbox-ico > input:eq(3)').nicelabel({
uselabel: false
});
});
</script>
</html>

Опубликовать ( 0 )

Вы можете оставить комментарий после Вход в систему

1
https://api.gitlife.ru/oschina-mirror/pjy-jquery-plugin.git
git@api.gitlife.ru:oschina-mirror/pjy-jquery-plugin.git
oschina-mirror
pjy-jquery-plugin
pjy-jquery-plugin
master