trunk
66
yii/assets/14c4eb31/pager.css
Normal file
@ -0,0 +1,66 @@
|
||||
/**
|
||||
* CSS styles for CLinkPager.
|
||||
*
|
||||
* @author Qiang Xue <qiang.xue@gmail.com>
|
||||
* @link http://www.yiiframework.com/
|
||||
* @copyright 2008-2010 Yii Software LLC
|
||||
* @license http://www.yiiframework.com/license/
|
||||
* @since 1.0
|
||||
*/
|
||||
|
||||
ul.yiiPager
|
||||
{
|
||||
font-size:11px;
|
||||
border:0;
|
||||
margin:0;
|
||||
padding:0;
|
||||
line-height:100%;
|
||||
display:inline;
|
||||
}
|
||||
|
||||
ul.yiiPager li
|
||||
{
|
||||
display:inline;
|
||||
}
|
||||
|
||||
ul.yiiPager a:link,
|
||||
ul.yiiPager a:visited
|
||||
{
|
||||
border:solid 1px #9aafe5;
|
||||
font-weight:bold;
|
||||
color:#0e509e;
|
||||
padding:1px 6px;
|
||||
text-decoration:none;
|
||||
}
|
||||
|
||||
ul.yiiPager .page a
|
||||
{
|
||||
font-weight:normal;
|
||||
}
|
||||
|
||||
ul.yiiPager a:hover
|
||||
{
|
||||
border:solid 1px #0e509e;
|
||||
}
|
||||
|
||||
ul.yiiPager .selected a
|
||||
{
|
||||
background:#2e6ab1;
|
||||
color:#FFFFFF;
|
||||
font-weight:bold;
|
||||
}
|
||||
|
||||
ul.yiiPager .hidden a
|
||||
{
|
||||
border:solid 1px #DEDEDE;
|
||||
color:#888888;
|
||||
}
|
||||
|
||||
/**
|
||||
* Hide first and last buttons by default.
|
||||
*/
|
||||
ul.yiiPager .first,
|
||||
ul.yiiPager .last
|
||||
{
|
||||
display:none;
|
||||
}
|
35
yii/assets/254ed3a0/css/ie.css
Normal file
@ -0,0 +1,35 @@
|
||||
/* -----------------------------------------------------------------------
|
||||
|
||||
|
||||
Blueprint CSS Framework 0.9
|
||||
http://blueprintcss.org
|
||||
|
||||
* Copyright (c) 2007-Present. See LICENSE for more info.
|
||||
* See README for instructions on how to use Blueprint.
|
||||
* For credits and origins, see AUTHORS.
|
||||
* This is a compressed file. See the sources in the 'src' directory.
|
||||
|
||||
----------------------------------------------------------------------- */
|
||||
|
||||
/* ie.css */
|
||||
body {text-align:center;}
|
||||
.container {text-align:left;}
|
||||
* html .column, * html div.span-1, * html div.span-2, * html div.span-3, * html div.span-4, * html div.span-5, * html div.span-6, * html div.span-7, * html div.span-8, * html div.span-9, * html div.span-10, * html div.span-11, * html div.span-12, * html div.span-13, * html div.span-14, * html div.span-15, * html div.span-16, * html div.span-17, * html div.span-18, * html div.span-19, * html div.span-20, * html div.span-21, * html div.span-22, * html div.span-23, * html div.span-24 {display:inline;overflow-x:hidden;}
|
||||
* html legend {margin:0px -8px 16px 0;padding:0;}
|
||||
sup {vertical-align:text-top;}
|
||||
sub {vertical-align:text-bottom;}
|
||||
html>body p code {*white-space:normal;}
|
||||
hr {margin:-8px auto 11px;}
|
||||
img {-ms-interpolation-mode:bicubic;}
|
||||
.clearfix, .container {display:inline-block;}
|
||||
* html .clearfix, * html .container {height:1%;}
|
||||
fieldset {padding-top:0;}
|
||||
textarea {overflow:auto;}
|
||||
input.text, input.title, textarea {background-color:#fff;border:1px solid #bbb;}
|
||||
input.text:focus, input.title:focus {border-color:#666;}
|
||||
input.text, input.title, textarea, select {margin:0.5em 0;}
|
||||
input.checkbox, input.radio {position:relative;top:.25em;}
|
||||
form.inline div, form.inline p {vertical-align:middle;}
|
||||
form.inline label {position:relative;top:-0.25em;}
|
||||
form.inline input.checkbox, form.inline input.radio, form.inline input.button, form.inline button {margin:0.5em 0;}
|
||||
button, input.button {position:relative;top:0.25em;}
|
528
yii/assets/254ed3a0/css/main.css
Normal file
@ -0,0 +1,528 @@
|
||||
body
|
||||
{
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
color: #555;
|
||||
font: normal 10pt Arial,Helvetica,Verdana,"DejaVu Sans","Bitstream Vera Sans",Geneva,sans-serif;
|
||||
background: #EFEFEF;
|
||||
}
|
||||
|
||||
h1
|
||||
{
|
||||
font-size: 1.6em;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
h2
|
||||
{
|
||||
font-size: 1.4em;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
h3
|
||||
{
|
||||
font-size: 1.2em;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
#page
|
||||
{
|
||||
margin-top: 5px;
|
||||
margin-bottom: 5px;
|
||||
background: white;
|
||||
border: 1px solid #C9E0ED;
|
||||
}
|
||||
|
||||
#header
|
||||
{
|
||||
padding: 0px;
|
||||
margin: 0px 20px;
|
||||
border-bottom: 1px solid #C9E0ED;
|
||||
}
|
||||
|
||||
#content
|
||||
{
|
||||
padding: 20px;
|
||||
min-height: 400px;
|
||||
}
|
||||
|
||||
#sidebar
|
||||
{
|
||||
padding: 20px 0 20px 20px;
|
||||
}
|
||||
|
||||
#footer
|
||||
{
|
||||
margin: 0 auto;
|
||||
width: 950px;
|
||||
font-size: 0.8em;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
#logo
|
||||
{
|
||||
padding: 5px 0px;
|
||||
}
|
||||
|
||||
#logo a
|
||||
{
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
#header .top-menus
|
||||
{
|
||||
margin: 20px 0px;
|
||||
float: right;
|
||||
}
|
||||
|
||||
div.flash-error, div.flash-notice, div.flash-success
|
||||
{
|
||||
padding:.8em;
|
||||
margin-bottom:1em;
|
||||
border:2px solid #ddd;
|
||||
}
|
||||
|
||||
div.flash-error
|
||||
{
|
||||
background:#FBE3E4;
|
||||
color:#8a1f11;
|
||||
border-color:#FBC2C4;
|
||||
}
|
||||
|
||||
div.flash-notice
|
||||
{
|
||||
background:#FFF6BF;
|
||||
color:#514721;
|
||||
border-color:#FFD324;
|
||||
}
|
||||
|
||||
div.flash-success
|
||||
{
|
||||
background:#E6EFC2;
|
||||
color:#264409;
|
||||
border-color:#C6D880;
|
||||
}
|
||||
|
||||
div.flash-error a
|
||||
{
|
||||
color:#8a1f11;
|
||||
}
|
||||
|
||||
div.flash-notice a
|
||||
{
|
||||
color:#514721;
|
||||
}
|
||||
|
||||
div.flash-success a
|
||||
{
|
||||
color:#264409;
|
||||
}
|
||||
|
||||
div.view
|
||||
{
|
||||
padding: 10px;
|
||||
margin: 10px 0;
|
||||
border: 1px solid #C9E0ED;
|
||||
}
|
||||
|
||||
div.breadcrumbs
|
||||
{
|
||||
font-size: 0.9em;
|
||||
padding: 5px 20px;
|
||||
}
|
||||
|
||||
div.breadcrumbs span
|
||||
{
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
div.search-form
|
||||
{
|
||||
padding: 10px;
|
||||
margin: 10px 0;
|
||||
background: #eee;
|
||||
}
|
||||
|
||||
.portlet
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
.portlet-decoration
|
||||
{
|
||||
padding: 3px 8px;
|
||||
background: #79B4DC;
|
||||
border-left: 5px solid #6293B3;
|
||||
}
|
||||
|
||||
.portlet-title
|
||||
{
|
||||
font-size: 12px;
|
||||
font-weight: bold;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
color: white;
|
||||
}
|
||||
|
||||
.portlet-content
|
||||
{
|
||||
font-size:0.9em;
|
||||
margin: 0 0 15px 0;
|
||||
padding: 5px 8px;
|
||||
background:#EFFDFF;
|
||||
}
|
||||
|
||||
.portlet-content ul
|
||||
{
|
||||
list-style-image:none;
|
||||
list-style-position:outside;
|
||||
list-style-type:none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.portlet-content li
|
||||
{
|
||||
padding: 2px 0 4px 0px;
|
||||
}
|
||||
|
||||
div.form
|
||||
{
|
||||
}
|
||||
|
||||
div.form input,
|
||||
div.form textarea,
|
||||
div.form select
|
||||
{
|
||||
margin: 0.2em 0 0.5em 0;
|
||||
}
|
||||
|
||||
div.form fieldset
|
||||
{
|
||||
border: 1px solid #DDD;
|
||||
padding: 10px;
|
||||
margin: 0 0 10px 0;
|
||||
-moz-border-radius:7px;
|
||||
}
|
||||
|
||||
div.form label
|
||||
{
|
||||
font-weight: bold;
|
||||
font-size: 0.9em;
|
||||
display: block;
|
||||
}
|
||||
|
||||
div.form .row
|
||||
{
|
||||
margin: 5px 0;
|
||||
}
|
||||
|
||||
div.form .row.buttons
|
||||
{
|
||||
padding: 5px;
|
||||
margin: 10px 0;
|
||||
}
|
||||
|
||||
div.form .row.buttons input
|
||||
{
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
div.form .hint
|
||||
{
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
color: #999;
|
||||
}
|
||||
|
||||
div.form .note
|
||||
{
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
div.form span.required
|
||||
{
|
||||
color: red;
|
||||
}
|
||||
|
||||
div.form div.error label,
|
||||
div.form label.error,
|
||||
div.form span.error
|
||||
{
|
||||
color: #C00;
|
||||
}
|
||||
|
||||
div.form div.error input,
|
||||
div.form div.error textarea,
|
||||
div.form div.error select,
|
||||
div.form input.error,
|
||||
div.form textarea.error,
|
||||
div.form select.error
|
||||
{
|
||||
background: #FEE;
|
||||
border-color: #C00;
|
||||
}
|
||||
|
||||
div.form div.success input,
|
||||
div.form div.success textarea,
|
||||
div.form div.success select,
|
||||
div.form input.success,
|
||||
div.form textarea.success,
|
||||
div.form select.success
|
||||
{
|
||||
background: #E6EFC2;
|
||||
border-color: #C6D880;
|
||||
}
|
||||
|
||||
|
||||
div.form .errorSummary
|
||||
{
|
||||
border: 2px solid #C00;
|
||||
padding: 7px 7px 12px 7px;
|
||||
margin: 0 0 20px 0;
|
||||
background: #FEE;
|
||||
font-size: 0.9em;
|
||||
}
|
||||
|
||||
div.form .errorMessage
|
||||
{
|
||||
color: red;
|
||||
font-size: 0.9em;
|
||||
}
|
||||
|
||||
div.form .errorSummary p
|
||||
{
|
||||
margin: 0;
|
||||
padding: 5px;
|
||||
}
|
||||
|
||||
div.form .errorSummary ul
|
||||
{
|
||||
margin: 0;
|
||||
padding: 0 0 0 20px;
|
||||
}
|
||||
|
||||
div.wide.form label
|
||||
{
|
||||
float: left;
|
||||
margin-right: 10px;
|
||||
position: relative;
|
||||
text-align: right;
|
||||
width: 100px;
|
||||
}
|
||||
|
||||
div.wide.form .row
|
||||
{
|
||||
clear: left;
|
||||
}
|
||||
|
||||
div.wide.form .buttons, div.wide.form .hint, div.wide.form .errorMessage
|
||||
{
|
||||
clear: left;
|
||||
padding-left: 110px;
|
||||
}
|
||||
|
||||
div.form .tooltip
|
||||
{
|
||||
display: none;
|
||||
background-color:#EFFDFF;
|
||||
border:1px solid #79B4DC;
|
||||
padding: 10px;
|
||||
width: 300px;
|
||||
}
|
||||
|
||||
div.form .tooltip ul
|
||||
{
|
||||
margin: 0;
|
||||
padding: 10px 0 0 20px;
|
||||
}
|
||||
|
||||
div.form .tooltip code
|
||||
{
|
||||
color: #CA0EE3;
|
||||
font-size:0.9em;
|
||||
}
|
||||
|
||||
div.form.login
|
||||
{
|
||||
border: 1px solid #C9E0ED;
|
||||
width: 200px;
|
||||
margin: 0 auto;
|
||||
margin-top: 50px;
|
||||
margin-bottom: 50px;
|
||||
padding: 20px 10px 10px 10px;
|
||||
text-align: center;
|
||||
-moz-border-radius: 5px;
|
||||
-webkit-border-radius: 5px;
|
||||
}
|
||||
|
||||
div.form.login p
|
||||
{
|
||||
margin: 0 0 10px 0;
|
||||
}
|
||||
|
||||
div.form.gii .row.sticky .value, span.sticky
|
||||
{
|
||||
padding: 3px;
|
||||
background: lightyellow;
|
||||
}
|
||||
|
||||
div.form.gii .row.template select
|
||||
{
|
||||
width: 420px;
|
||||
}
|
||||
|
||||
div.form.gii table.preview
|
||||
{
|
||||
border-collapse: collapse;
|
||||
}
|
||||
|
||||
div.form.gii table.preview th
|
||||
{
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
div.form.gii table.preview th.confirm
|
||||
{
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
div.form.gii table.preview th.confirm label
|
||||
{
|
||||
display: inline;
|
||||
}
|
||||
|
||||
div.form.gii table.preview td.confirm
|
||||
{
|
||||
width: 80px;
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
div.form.gii table.preview td.confirm input
|
||||
{
|
||||
margin:0;
|
||||
}
|
||||
|
||||
div.form.gii table.preview td.confirm label
|
||||
{
|
||||
display: inline;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
div.form.gii table.preview,
|
||||
div.form.gii table.preview th,
|
||||
div.form.gii table.preview td
|
||||
{
|
||||
border: 1px solid #529EC6;
|
||||
}
|
||||
|
||||
div.form.gii table.preview tr.skip
|
||||
{
|
||||
background-color: #eee;
|
||||
}
|
||||
|
||||
div.form.gii table.preview tr.new
|
||||
{
|
||||
background-color: #C5FBBD;
|
||||
}
|
||||
|
||||
div.form.gii table.preview tr.overwrite
|
||||
{
|
||||
background-color: #FFE0E1;
|
||||
}
|
||||
|
||||
div.form.gii pre.results
|
||||
{
|
||||
overflow: auto;
|
||||
background-color: gray;
|
||||
max-height: 300px;
|
||||
color: white;
|
||||
padding: 10px;
|
||||
}
|
||||
|
||||
div.form.gii div.success
|
||||
{
|
||||
background: #C5FBBD;
|
||||
border: 1px solid #76C376;
|
||||
padding: 10px;
|
||||
margin: 10px 0;
|
||||
}
|
||||
|
||||
div.form.gii div.error
|
||||
{
|
||||
background: #FFE0E1;
|
||||
border: 1px solid #FFA0A2;
|
||||
padding: 10px;
|
||||
margin: 10px 0;
|
||||
}
|
||||
|
||||
div.form.gii div.success code
|
||||
{
|
||||
overflow: auto;
|
||||
display: block;
|
||||
padding: 5px;
|
||||
font-size: 12px;
|
||||
background: white;
|
||||
}
|
||||
|
||||
div.form.gii pre.results span.error
|
||||
{
|
||||
background: #FFE0E1;
|
||||
color: black;
|
||||
padding: 1px;
|
||||
}
|
||||
|
||||
#fancybox-inner .error
|
||||
{
|
||||
color: red;
|
||||
}
|
||||
|
||||
#fancybox-inner .title
|
||||
{
|
||||
font-size: 12px;
|
||||
font-weight: bold;
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
#fancybox-inner .buttons
|
||||
{
|
||||
float: right;
|
||||
padding: 0 10px 0 0;
|
||||
}
|
||||
|
||||
#fancybox-inner .content
|
||||
{
|
||||
background: #F0F4FF;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
#fancybox-inner pre.diff
|
||||
{
|
||||
margin:0;
|
||||
}
|
||||
|
||||
#fancybox-inner pre.diff del
|
||||
{
|
||||
background: pink;
|
||||
}
|
||||
|
||||
#fancybox-inner pre.diff ins
|
||||
{
|
||||
background: lightgreen;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
#fancybox-wrap #tip7-title
|
||||
{
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
#fancybox-wrap #tip7-title b
|
||||
{
|
||||
display: block;
|
||||
}
|
||||
|
||||
#fancybox-wrap #tip7-title span
|
||||
{
|
||||
float: right;
|
||||
}
|
29
yii/assets/254ed3a0/css/print.css
Normal file
@ -0,0 +1,29 @@
|
||||
/* -----------------------------------------------------------------------
|
||||
|
||||
|
||||
Blueprint CSS Framework 0.9
|
||||
http://blueprintcss.org
|
||||
|
||||
* Copyright (c) 2007-Present. See LICENSE for more info.
|
||||
* See README for instructions on how to use Blueprint.
|
||||
* For credits and origins, see AUTHORS.
|
||||
* This is a compressed file. See the sources in the 'src' directory.
|
||||
|
||||
----------------------------------------------------------------------- */
|
||||
|
||||
/* print.css */
|
||||
body {line-height:1.5;font-family:"Helvetica Neue", Arial, Helvetica, sans-serif;color:#000;background:none;font-size:10pt;}
|
||||
.container {background:none;}
|
||||
hr {background:#ccc;color:#ccc;width:100%;height:2px;margin:2em 0;padding:0;border:none;}
|
||||
hr.space {background:#fff;color:#fff;visibility:hidden;}
|
||||
h1, h2, h3, h4, h5, h6 {font-family:"Helvetica Neue", Arial, "Lucida Grande", sans-serif;}
|
||||
code {font:.9em "Courier New", Monaco, Courier, monospace;}
|
||||
a img {border:none;}
|
||||
p img.top {margin-top:0;}
|
||||
blockquote {margin:1.5em;padding:1em;font-style:italic;font-size:.9em;}
|
||||
.small {font-size:.9em;}
|
||||
.large {font-size:1.1em;}
|
||||
.quiet {color:#999;}
|
||||
.hide {display:none;}
|
||||
a:link, a:visited {background:transparent;font-weight:700;text-decoration:underline;}
|
||||
a:link:after, a:visited:after {content:" (" attr(href) ")";font-size:90%;}
|
235
yii/assets/254ed3a0/css/screen.css
Normal file
@ -0,0 +1,235 @@
|
||||
/* -----------------------------------------------------------------------
|
||||
|
||||
|
||||
Blueprint CSS Framework 0.9
|
||||
http://blueprintcss.org
|
||||
|
||||
* Copyright (c) 2007-Present. See LICENSE for more info.
|
||||
* See README for instructions on how to use Blueprint.
|
||||
* For credits and origins, see AUTHORS.
|
||||
* This is a compressed file. See the sources in the 'src' directory.
|
||||
|
||||
----------------------------------------------------------------------- */
|
||||
|
||||
/* reset.css */
|
||||
html, body, div, span, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, code, del, dfn, em, img, q, dl, dt, dd, ol, ul, li, fieldset, form, label, legend, table, caption, tbody, tfoot, thead, tr, th, td {margin:0;padding:0;border:0;font-weight:inherit;font-style:inherit;font-size:100%;font-family:inherit;vertical-align:baseline;}
|
||||
body {line-height:1.5;}
|
||||
table {border-collapse:separate;border-spacing:0;}
|
||||
caption, th, td {text-align:left;font-weight:normal;}
|
||||
table, td, th {vertical-align:middle;}
|
||||
blockquote:before, blockquote:after, q:before, q:after {content:"";}
|
||||
blockquote, q {quotes:"" "";}
|
||||
a img {border:none;}
|
||||
|
||||
/* typography.css */
|
||||
html {font-size:100.01%;}
|
||||
body {font-size:75%;color:#222;background:#fff;font-family:"Helvetica Neue", Arial, Helvetica, sans-serif;}
|
||||
h1, h2, h3, h4, h5, h6 {font-weight:normal;color:#111;}
|
||||
h1 {font-size:2em;line-height:1;margin-bottom:0.5em;}
|
||||
h2 {font-size:1.6em;margin-bottom:0.75em;}
|
||||
h3 {font-size:1.4em;line-height:1;margin-bottom:1em;}
|
||||
h4 {font-size:1.2em;line-height:1.25;margin-bottom:1.25em;}
|
||||
h5 {font-size:1em;font-weight:bold;margin-bottom:1.5em;}
|
||||
h6 {font-size:1em;font-weight:bold;}
|
||||
h1 img, h2 img, h3 img, h4 img, h5 img, h6 img {margin:0;}
|
||||
p {margin:0 0 1.5em;}
|
||||
p img.left {float:left;margin:1.5em 1.5em 1.5em 0;padding:0;}
|
||||
p img.right {float:right;margin:1.5em 0 1.5em 1.5em;}
|
||||
a:focus, a:hover {color:#000;}
|
||||
a {color:#009;text-decoration:underline;}
|
||||
blockquote {margin:1.5em;color:#666;font-style:italic;}
|
||||
strong {font-weight:bold;}
|
||||
em, dfn {font-style:italic;}
|
||||
dfn {font-weight:bold;}
|
||||
sup, sub {line-height:0;}
|
||||
abbr, acronym {border-bottom:1px dotted #666;}
|
||||
address {margin:0 0 1.5em;font-style:italic;}
|
||||
del {color:#666;}
|
||||
pre {margin:1.5em 0;white-space:pre;}
|
||||
pre, code, tt {font:1em 'andale mono', 'lucida console', monospace;line-height:1.5;}
|
||||
li ul, li ol {margin:0;}
|
||||
ul, ol {margin:0 1.5em 1.5em 0;padding-left:3.333em;}
|
||||
ul {list-style-type:disc;}
|
||||
ol {list-style-type:decimal;}
|
||||
dl {margin:0 0 1.5em 0;}
|
||||
dl dt {font-weight:bold;}
|
||||
dd {margin-left:1.5em;}
|
||||
table {margin-bottom:1.4em;width:100%;}
|
||||
th {font-weight:bold;}
|
||||
thead th {background:#c3d9ff;}
|
||||
th, td, caption {padding:4px 10px 4px 5px;}
|
||||
tfoot {font-style:italic;}
|
||||
caption {background:#eee;}
|
||||
.small {font-size:.8em;margin-bottom:1.875em;line-height:1.875em;}
|
||||
.large {font-size:1.2em;line-height:2.5em;margin-bottom:1.25em;}
|
||||
.hide {display:none;}
|
||||
.quiet {color:#666;}
|
||||
.loud {color:#000;}
|
||||
.highlight {background:#ff0;}
|
||||
.added {background:#060;color:#fff;}
|
||||
.removed {background:#900;color:#fff;}
|
||||
.first {margin-left:0;padding-left:0;}
|
||||
.last {margin-right:0;padding-right:0;}
|
||||
.top {margin-top:0;padding-top:0;}
|
||||
.bottom {margin-bottom:0;padding-bottom:0;}
|
||||
|
||||
/* grid.css */
|
||||
.container {width:950px;margin:0 auto;}
|
||||
.showgrid {background:url(src/grid.png);}
|
||||
.column, div.span-1, div.span-2, div.span-3, div.span-4, div.span-5, div.span-6, div.span-7, div.span-8, div.span-9, div.span-10, div.span-11, div.span-12, div.span-13, div.span-14, div.span-15, div.span-16, div.span-17, div.span-18, div.span-19, div.span-20, div.span-21, div.span-22, div.span-23, div.span-24 {float:left;margin-right:10px;}
|
||||
.last, div.last {margin-right:0;}
|
||||
.span-1 {width:30px;}
|
||||
.span-2 {width:70px;}
|
||||
.span-3 {width:110px;}
|
||||
.span-4 {width:150px;}
|
||||
.span-5 {width:190px;}
|
||||
.span-6 {width:230px;}
|
||||
.span-7 {width:270px;}
|
||||
.span-8 {width:310px;}
|
||||
.span-9 {width:350px;}
|
||||
.span-10 {width:390px;}
|
||||
.span-11 {width:430px;}
|
||||
.span-12 {width:470px;}
|
||||
.span-13 {width:510px;}
|
||||
.span-14 {width:550px;}
|
||||
.span-15 {width:590px;}
|
||||
.span-16 {width:630px;}
|
||||
.span-17 {width:670px;}
|
||||
.span-18 {width:710px;}
|
||||
.span-19 {width:750px;}
|
||||
.span-20 {width:790px;}
|
||||
.span-21 {width:830px;}
|
||||
.span-22 {width:870px;}
|
||||
.span-23 {width:910px;}
|
||||
.span-24, div.span-24 {width:950px;margin-right:0;}
|
||||
input.span-1, textarea.span-1, input.span-2, textarea.span-2, input.span-3, textarea.span-3, input.span-4, textarea.span-4, input.span-5, textarea.span-5, input.span-6, textarea.span-6, input.span-7, textarea.span-7, input.span-8, textarea.span-8, input.span-9, textarea.span-9, input.span-10, textarea.span-10, input.span-11, textarea.span-11, input.span-12, textarea.span-12, input.span-13, textarea.span-13, input.span-14, textarea.span-14, input.span-15, textarea.span-15, input.span-16, textarea.span-16, input.span-17, textarea.span-17, input.span-18, textarea.span-18, input.span-19, textarea.span-19, input.span-20, textarea.span-20, input.span-21, textarea.span-21, input.span-22, textarea.span-22, input.span-23, textarea.span-23, input.span-24, textarea.span-24 {border-left-width:1px!important;border-right-width:1px!important;padding-left:5px!important;padding-right:5px!important;}
|
||||
input.span-1, textarea.span-1 {width:18px!important;}
|
||||
input.span-2, textarea.span-2 {width:58px!important;}
|
||||
input.span-3, textarea.span-3 {width:98px!important;}
|
||||
input.span-4, textarea.span-4 {width:138px!important;}
|
||||
input.span-5, textarea.span-5 {width:178px!important;}
|
||||
input.span-6, textarea.span-6 {width:218px!important;}
|
||||
input.span-7, textarea.span-7 {width:258px!important;}
|
||||
input.span-8, textarea.span-8 {width:298px!important;}
|
||||
input.span-9, textarea.span-9 {width:338px!important;}
|
||||
input.span-10, textarea.span-10 {width:378px!important;}
|
||||
input.span-11, textarea.span-11 {width:418px!important;}
|
||||
input.span-12, textarea.span-12 {width:458px!important;}
|
||||
input.span-13, textarea.span-13 {width:498px!important;}
|
||||
input.span-14, textarea.span-14 {width:538px!important;}
|
||||
input.span-15, textarea.span-15 {width:578px!important;}
|
||||
input.span-16, textarea.span-16 {width:618px!important;}
|
||||
input.span-17, textarea.span-17 {width:658px!important;}
|
||||
input.span-18, textarea.span-18 {width:698px!important;}
|
||||
input.span-19, textarea.span-19 {width:738px!important;}
|
||||
input.span-20, textarea.span-20 {width:778px!important;}
|
||||
input.span-21, textarea.span-21 {width:818px!important;}
|
||||
input.span-22, textarea.span-22 {width:858px!important;}
|
||||
input.span-23, textarea.span-23 {width:898px!important;}
|
||||
input.span-24, textarea.span-24 {width:938px!important;}
|
||||
.append-1 {padding-right:40px;}
|
||||
.append-2 {padding-right:80px;}
|
||||
.append-3 {padding-right:120px;}
|
||||
.append-4 {padding-right:160px;}
|
||||
.append-5 {padding-right:200px;}
|
||||
.append-6 {padding-right:240px;}
|
||||
.append-7 {padding-right:280px;}
|
||||
.append-8 {padding-right:320px;}
|
||||
.append-9 {padding-right:360px;}
|
||||
.append-10 {padding-right:400px;}
|
||||
.append-11 {padding-right:440px;}
|
||||
.append-12 {padding-right:480px;}
|
||||
.append-13 {padding-right:520px;}
|
||||
.append-14 {padding-right:560px;}
|
||||
.append-15 {padding-right:600px;}
|
||||
.append-16 {padding-right:640px;}
|
||||
.append-17 {padding-right:680px;}
|
||||
.append-18 {padding-right:720px;}
|
||||
.append-19 {padding-right:760px;}
|
||||
.append-20 {padding-right:800px;}
|
||||
.append-21 {padding-right:840px;}
|
||||
.append-22 {padding-right:880px;}
|
||||
.append-23 {padding-right:920px;}
|
||||
.prepend-1 {padding-left:40px;}
|
||||
.prepend-2 {padding-left:80px;}
|
||||
.prepend-3 {padding-left:120px;}
|
||||
.prepend-4 {padding-left:160px;}
|
||||
.prepend-5 {padding-left:200px;}
|
||||
.prepend-6 {padding-left:240px;}
|
||||
.prepend-7 {padding-left:280px;}
|
||||
.prepend-8 {padding-left:320px;}
|
||||
.prepend-9 {padding-left:360px;}
|
||||
.prepend-10 {padding-left:400px;}
|
||||
.prepend-11 {padding-left:440px;}
|
||||
.prepend-12 {padding-left:480px;}
|
||||
.prepend-13 {padding-left:520px;}
|
||||
.prepend-14 {padding-left:560px;}
|
||||
.prepend-15 {padding-left:600px;}
|
||||
.prepend-16 {padding-left:640px;}
|
||||
.prepend-17 {padding-left:680px;}
|
||||
.prepend-18 {padding-left:720px;}
|
||||
.prepend-19 {padding-left:760px;}
|
||||
.prepend-20 {padding-left:800px;}
|
||||
.prepend-21 {padding-left:840px;}
|
||||
.prepend-22 {padding-left:880px;}
|
||||
.prepend-23 {padding-left:920px;}
|
||||
div.border {padding-right:4px;margin-right:5px;border-right:1px solid #eee;}
|
||||
div.colborder {padding-right:24px;margin-right:25px;border-right:1px solid #eee;}
|
||||
.pull-1 {margin-left:-40px;}
|
||||
.pull-2 {margin-left:-80px;}
|
||||
.pull-3 {margin-left:-120px;}
|
||||
.pull-4 {margin-left:-160px;}
|
||||
.pull-5 {margin-left:-200px;}
|
||||
.pull-6 {margin-left:-240px;}
|
||||
.pull-7 {margin-left:-280px;}
|
||||
.pull-8 {margin-left:-320px;}
|
||||
.pull-9 {margin-left:-360px;}
|
||||
.pull-10 {margin-left:-400px;}
|
||||
.pull-11 {margin-left:-440px;}
|
||||
.pull-12 {margin-left:-480px;}
|
||||
.pull-13 {margin-left:-520px;}
|
||||
.pull-14 {margin-left:-560px;}
|
||||
.pull-15 {margin-left:-600px;}
|
||||
.pull-16 {margin-left:-640px;}
|
||||
.pull-17 {margin-left:-680px;}
|
||||
.pull-18 {margin-left:-720px;}
|
||||
.pull-19 {margin-left:-760px;}
|
||||
.pull-20 {margin-left:-800px;}
|
||||
.pull-21 {margin-left:-840px;}
|
||||
.pull-22 {margin-left:-880px;}
|
||||
.pull-23 {margin-left:-920px;}
|
||||
.pull-24 {margin-left:-960px;}
|
||||
.pull-1, .pull-2, .pull-3, .pull-4, .pull-5, .pull-6, .pull-7, .pull-8, .pull-9, .pull-10, .pull-11, .pull-12, .pull-13, .pull-14, .pull-15, .pull-16, .pull-17, .pull-18, .pull-19, .pull-20, .pull-21, .pull-22, .pull-23, .pull-24 {float:left;position:relative;}
|
||||
.push-1 {margin:0 -40px 1.5em 40px;}
|
||||
.push-2 {margin:0 -80px 1.5em 80px;}
|
||||
.push-3 {margin:0 -120px 1.5em 120px;}
|
||||
.push-4 {margin:0 -160px 1.5em 160px;}
|
||||
.push-5 {margin:0 -200px 1.5em 200px;}
|
||||
.push-6 {margin:0 -240px 1.5em 240px;}
|
||||
.push-7 {margin:0 -280px 1.5em 280px;}
|
||||
.push-8 {margin:0 -320px 1.5em 320px;}
|
||||
.push-9 {margin:0 -360px 1.5em 360px;}
|
||||
.push-10 {margin:0 -400px 1.5em 400px;}
|
||||
.push-11 {margin:0 -440px 1.5em 440px;}
|
||||
.push-12 {margin:0 -480px 1.5em 480px;}
|
||||
.push-13 {margin:0 -520px 1.5em 520px;}
|
||||
.push-14 {margin:0 -560px 1.5em 560px;}
|
||||
.push-15 {margin:0 -600px 1.5em 600px;}
|
||||
.push-16 {margin:0 -640px 1.5em 640px;}
|
||||
.push-17 {margin:0 -680px 1.5em 680px;}
|
||||
.push-18 {margin:0 -720px 1.5em 720px;}
|
||||
.push-19 {margin:0 -760px 1.5em 760px;}
|
||||
.push-20 {margin:0 -800px 1.5em 800px;}
|
||||
.push-21 {margin:0 -840px 1.5em 840px;}
|
||||
.push-22 {margin:0 -880px 1.5em 880px;}
|
||||
.push-23 {margin:0 -920px 1.5em 920px;}
|
||||
.push-24 {margin:0 -960px 1.5em 960px;}
|
||||
.push-1, .push-2, .push-3, .push-4, .push-5, .push-6, .push-7, .push-8, .push-9, .push-10, .push-11, .push-12, .push-13, .push-14, .push-15, .push-16, .push-17, .push-18, .push-19, .push-20, .push-21, .push-22, .push-23, .push-24 {float:right;position:relative;}
|
||||
.prepend-top {margin-top:1.5em;}
|
||||
.append-bottom {margin-bottom:1.5em;}
|
||||
.box {padding:1.5em;margin-bottom:1.5em;background:#E5ECF9;}
|
||||
hr {background:#ddd;color:#ddd;clear:both;float:none;width:100%;height:.1em;margin:0 0 1.45em;border:none;}
|
||||
hr.space {background:#fff;color:#fff;visibility:hidden;}
|
||||
.clearfix:after, .container:after {content:"\0020";display:block;height:0;clear:both;visibility:hidden;overflow:hidden;}
|
||||
.clearfix, .container {display:block;}
|
||||
.clear {clear:both;}
|
BIN
yii/assets/254ed3a0/images/logo.png
Normal file
After Width: | Height: | Size: 7.0 KiB |
BIN
yii/assets/254ed3a0/js/fancybox/blank.gif
Normal file
After Width: | Height: | Size: 43 B |
BIN
yii/assets/254ed3a0/js/fancybox/fancy_close.png
Normal file
After Width: | Height: | Size: 1.0 KiB |
BIN
yii/assets/254ed3a0/js/fancybox/fancy_loading.png
Normal file
After Width: | Height: | Size: 7.9 KiB |
BIN
yii/assets/254ed3a0/js/fancybox/fancy_nav_left.png
Normal file
After Width: | Height: | Size: 1.0 KiB |
BIN
yii/assets/254ed3a0/js/fancybox/fancy_nav_right.png
Normal file
After Width: | Height: | Size: 1.0 KiB |
BIN
yii/assets/254ed3a0/js/fancybox/fancy_shadow_e.png
Normal file
After Width: | Height: | Size: 107 B |
BIN
yii/assets/254ed3a0/js/fancybox/fancy_shadow_n.png
Normal file
After Width: | Height: | Size: 101 B |
BIN
yii/assets/254ed3a0/js/fancybox/fancy_shadow_ne.png
Normal file
After Width: | Height: | Size: 313 B |
BIN
yii/assets/254ed3a0/js/fancybox/fancy_shadow_nw.png
Normal file
After Width: | Height: | Size: 310 B |
BIN
yii/assets/254ed3a0/js/fancybox/fancy_shadow_s.png
Normal file
After Width: | Height: | Size: 107 B |
BIN
yii/assets/254ed3a0/js/fancybox/fancy_shadow_se.png
Normal file
After Width: | Height: | Size: 330 B |
BIN
yii/assets/254ed3a0/js/fancybox/fancy_shadow_sw.png
Normal file
After Width: | Height: | Size: 317 B |
BIN
yii/assets/254ed3a0/js/fancybox/fancy_shadow_w.png
Normal file
After Width: | Height: | Size: 99 B |
BIN
yii/assets/254ed3a0/js/fancybox/fancy_title_left.png
Normal file
After Width: | Height: | Size: 496 B |
BIN
yii/assets/254ed3a0/js/fancybox/fancy_title_main.png
Normal file
After Width: | Height: | Size: 96 B |
BIN
yii/assets/254ed3a0/js/fancybox/fancy_title_over.png
Normal file
After Width: | Height: | Size: 68 B |
BIN
yii/assets/254ed3a0/js/fancybox/fancy_title_right.png
Normal file
After Width: | Height: | Size: 495 B |
BIN
yii/assets/254ed3a0/js/fancybox/fancybox-x.png
Normal file
After Width: | Height: | Size: 159 B |
BIN
yii/assets/254ed3a0/js/fancybox/fancybox-y.png
Normal file
After Width: | Height: | Size: 128 B |
BIN
yii/assets/254ed3a0/js/fancybox/fancybox.png
Normal file
After Width: | Height: | Size: 14 KiB |
363
yii/assets/254ed3a0/js/fancybox/jquery.fancybox-1.3.1.css
Normal file
@ -0,0 +1,363 @@
|
||||
/*
|
||||
* FancyBox - jQuery Plugin
|
||||
* Simple and fancy lightbox alternative
|
||||
*
|
||||
* Examples and documentation at: http://fancybox.net
|
||||
*
|
||||
* Copyright (c) 2008 - 2010 Janis Skarnelis
|
||||
*
|
||||
* Version: 1.3.1 (05/03/2010)
|
||||
* Requires: jQuery v1.3+
|
||||
*
|
||||
* Dual licensed under the MIT and GPL licenses:
|
||||
* http://www.opensource.org/licenses/mit-license.php
|
||||
* http://www.gnu.org/licenses/gpl.html
|
||||
*/
|
||||
|
||||
#fancybox-loading {
|
||||
position: fixed;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
height: 40px;
|
||||
width: 40px;
|
||||
margin-top: -20px;
|
||||
margin-left: -20px;
|
||||
cursor: pointer;
|
||||
overflow: hidden;
|
||||
z-index: 1104;
|
||||
display: none;
|
||||
}
|
||||
|
||||
* html #fancybox-loading { /* IE6 */
|
||||
position: absolute;
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
#fancybox-loading div {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 40px;
|
||||
height: 480px;
|
||||
background-image: url('fancybox.png');
|
||||
}
|
||||
|
||||
#fancybox-overlay {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
background: #000;
|
||||
z-index: 1100;
|
||||
display: none;
|
||||
}
|
||||
|
||||
* html #fancybox-overlay { /* IE6 */
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
#fancybox-tmp {
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
border: 0;
|
||||
overflow: auto;
|
||||
display: none;
|
||||
}
|
||||
|
||||
#fancybox-wrap {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
margin: 0;
|
||||
padding: 20px;
|
||||
z-index: 1101;
|
||||
display: none;
|
||||
}
|
||||
|
||||
#fancybox-outer {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background: #FFF;
|
||||
}
|
||||
|
||||
#fancybox-inner {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 1px;
|
||||
height: 1px;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
outline: none;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
#fancybox-hide-sel-frame {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
#fancybox-close {
|
||||
position: absolute;
|
||||
top: -15px;
|
||||
right: -15px;
|
||||
width: 30px;
|
||||
height: 30px;
|
||||
background-image: url('fancybox.png');
|
||||
background-position: -40px 0px;
|
||||
cursor: pointer;
|
||||
z-index: 1103;
|
||||
display: none;
|
||||
}
|
||||
|
||||
#fancybox_error {
|
||||
color: #444;
|
||||
font: normal 12px/20px Arial;
|
||||
padding: 7px;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
#fancybox-content {
|
||||
height: auto;
|
||||
width: auto;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
#fancybox-img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
border: none;
|
||||
outline: none;
|
||||
line-height: 0;
|
||||
vertical-align: top;
|
||||
-ms-interpolation-mode: bicubic;
|
||||
}
|
||||
|
||||
#fancybox-frame {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
border: none;
|
||||
display: block;
|
||||
}
|
||||
|
||||
#fancybox-title {
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
font-family: Arial;
|
||||
font-size: 12px;
|
||||
z-index: 1102;
|
||||
}
|
||||
|
||||
.fancybox-title-inside {
|
||||
padding: 10px 0;
|
||||
text-align: center;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.fancybox-title-outside {
|
||||
padding-top: 5px;
|
||||
color: #FFF;
|
||||
text-align: center;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.fancybox-title-over {
|
||||
color: #FFF;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
#fancybox-title-over {
|
||||
padding: 10px;
|
||||
background-image: url('fancy_title_over.png');
|
||||
display: block;
|
||||
}
|
||||
|
||||
#fancybox-title-wrap {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
#fancybox-title-wrap span {
|
||||
height: 32px;
|
||||
float: left;
|
||||
}
|
||||
|
||||
#fancybox-title-left {
|
||||
padding-left: 15px;
|
||||
background-image: url('fancybox.png');
|
||||
background-position: -40px -90px;
|
||||
background-repeat: no-repeat;
|
||||
}
|
||||
|
||||
#fancybox-title-main {
|
||||
font-weight: bold;
|
||||
line-height: 29px;
|
||||
background-image: url('fancybox-x.png');
|
||||
background-position: 0px -40px;
|
||||
color: #FFF;
|
||||
}
|
||||
|
||||
#fancybox-title-right {
|
||||
padding-left: 15px;
|
||||
background-image: url('fancybox.png');
|
||||
background-position: -55px -90px;
|
||||
background-repeat: no-repeat;
|
||||
}
|
||||
|
||||
#fancybox-left, #fancybox-right {
|
||||
position: absolute;
|
||||
bottom: 0px;
|
||||
height: 100%;
|
||||
width: 35%;
|
||||
cursor: pointer;
|
||||
outline: none;
|
||||
background-image: url('blank.gif');
|
||||
z-index: 1102;
|
||||
display: none;
|
||||
}
|
||||
|
||||
#fancybox-left {
|
||||
left: 0px;
|
||||
}
|
||||
|
||||
#fancybox-right {
|
||||
right: 0px;
|
||||
}
|
||||
|
||||
#fancybox-left-ico, #fancybox-right-ico {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: -9999px;
|
||||
width: 30px;
|
||||
height: 30px;
|
||||
margin-top: -15px;
|
||||
cursor: pointer;
|
||||
z-index: 1102;
|
||||
display: block;
|
||||
}
|
||||
|
||||
#fancybox-left-ico {
|
||||
background-image: url('fancybox.png');
|
||||
background-position: -40px -30px;
|
||||
}
|
||||
|
||||
#fancybox-right-ico {
|
||||
background-image: url('fancybox.png');
|
||||
background-position: -40px -60px;
|
||||
}
|
||||
|
||||
#fancybox-left:hover, #fancybox-right:hover {
|
||||
visibility: visible; /* IE6 */
|
||||
}
|
||||
|
||||
#fancybox-left:hover span {
|
||||
left: 20px;
|
||||
}
|
||||
|
||||
#fancybox-right:hover span {
|
||||
left: auto;
|
||||
right: 20px;
|
||||
}
|
||||
|
||||
.fancy-bg {
|
||||
position: absolute;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
border: 0;
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
z-index: 1001;
|
||||
}
|
||||
|
||||
#fancy-bg-n {
|
||||
top: -20px;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
background-image: url('fancybox-x.png');
|
||||
}
|
||||
|
||||
#fancy-bg-ne {
|
||||
top: -20px;
|
||||
right: -20px;
|
||||
background-image: url('fancybox.png');
|
||||
background-position: -40px -162px;
|
||||
}
|
||||
|
||||
#fancy-bg-e {
|
||||
top: 0;
|
||||
right: -20px;
|
||||
height: 100%;
|
||||
background-image: url('fancybox-y.png');
|
||||
background-position: -20px 0px;
|
||||
}
|
||||
|
||||
#fancy-bg-se {
|
||||
bottom: -20px;
|
||||
right: -20px;
|
||||
background-image: url('fancybox.png');
|
||||
background-position: -40px -182px;
|
||||
}
|
||||
|
||||
#fancy-bg-s {
|
||||
bottom: -20px;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
background-image: url('fancybox-x.png');
|
||||
background-position: 0px -20px;
|
||||
}
|
||||
|
||||
#fancy-bg-sw {
|
||||
bottom: -20px;
|
||||
left: -20px;
|
||||
background-image: url('fancybox.png');
|
||||
background-position: -40px -142px;
|
||||
}
|
||||
|
||||
#fancy-bg-w {
|
||||
top: 0;
|
||||
left: -20px;
|
||||
height: 100%;
|
||||
background-image: url('fancybox-y.png');
|
||||
}
|
||||
|
||||
#fancy-bg-nw {
|
||||
top: -20px;
|
||||
left: -20px;
|
||||
background-image: url('fancybox.png');
|
||||
background-position: -40px -122px;
|
||||
}
|
||||
|
||||
/* IE */
|
||||
|
||||
#fancybox-loading.fancybox-ie div { background: transparent; filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_loading.png', sizingMethod='scale'); }
|
||||
.fancybox-ie #fancybox-close { background: transparent; filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_close.png', sizingMethod='scale'); }
|
||||
|
||||
.fancybox-ie #fancybox-title-over { background: transparent; filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_title_over.png', sizingMethod='scale'); zoom: 1; }
|
||||
.fancybox-ie #fancybox-title-left { background: transparent; filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_title_left.png', sizingMethod='scale'); }
|
||||
.fancybox-ie #fancybox-title-main { background: transparent; filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_title_main.png', sizingMethod='scale'); }
|
||||
.fancybox-ie #fancybox-title-right { background: transparent; filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_title_right.png', sizingMethod='scale'); }
|
||||
|
||||
.fancybox-ie #fancybox-left-ico { background: transparent; filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_nav_left.png', sizingMethod='scale'); }
|
||||
.fancybox-ie #fancybox-right-ico { background: transparent; filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_nav_right.png', sizingMethod='scale'); }
|
||||
|
||||
.fancybox-ie .fancy-bg { background: transparent !important; }
|
||||
|
||||
.fancybox-ie #fancy-bg-n { filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_shadow_n.png', sizingMethod='scale'); }
|
||||
.fancybox-ie #fancy-bg-ne { filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_shadow_ne.png', sizingMethod='scale'); }
|
||||
.fancybox-ie #fancy-bg-e { filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_shadow_e.png', sizingMethod='scale'); }
|
||||
.fancybox-ie #fancy-bg-se { filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_shadow_se.png', sizingMethod='scale'); }
|
||||
.fancybox-ie #fancy-bg-s { filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_shadow_s.png', sizingMethod='scale'); }
|
||||
.fancybox-ie #fancy-bg-sw { filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_shadow_sw.png', sizingMethod='scale'); }
|
||||
.fancybox-ie #fancy-bg-w { filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_shadow_w.png', sizingMethod='scale'); }
|
||||
.fancybox-ie #fancy-bg-nw { filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_shadow_nw.png', sizingMethod='scale'); }
|
@ -0,0 +1,44 @@
|
||||
/*
|
||||
* FancyBox - jQuery Plugin
|
||||
* Simple and fancy lightbox alternative
|
||||
*
|
||||
* Examples and documentation at: http://fancybox.net
|
||||
*
|
||||
* Copyright (c) 2008 - 2010 Janis Skarnelis
|
||||
*
|
||||
* Version: 1.3.1 (05/03/2010)
|
||||
* Requires: jQuery v1.3+
|
||||
*
|
||||
* Dual licensed under the MIT and GPL licenses:
|
||||
* http://www.opensource.org/licenses/mit-license.php
|
||||
* http://www.gnu.org/licenses/gpl.html
|
||||
*/
|
||||
|
||||
(function(b){var m,u,x,g,D,i,z,A,B,p=0,e={},q=[],n=0,c={},j=[],E=null,s=new Image,G=/\.(jpg|gif|png|bmp|jpeg)(.*)?$/i,S=/[^\.]\.(swf)\s*$/i,H,I=1,k,l,h=false,y=b.extend(b("<div/>")[0],{prop:0}),v=0,O=!b.support.opacity&&!window.XMLHttpRequest,J=function(){u.hide();s.onerror=s.onload=null;E&&E.abort();m.empty()},P=function(){b.fancybox('<p id="fancybox_error">The requested content cannot be loaded.<br />Please try again later.</p>',{scrolling:"no",padding:20,transitionIn:"none",transitionOut:"none"})},
|
||||
K=function(){return[b(window).width(),b(window).height(),b(document).scrollLeft(),b(document).scrollTop()]},T=function(){var a=K(),d={},f=c.margin,o=c.autoScale,t=(20+f)*2,w=(20+f)*2,r=c.padding*2;if(c.width.toString().indexOf("%")>-1){d.width=a[0]*parseFloat(c.width)/100-40;o=false}else d.width=c.width+r;if(c.height.toString().indexOf("%")>-1){d.height=a[1]*parseFloat(c.height)/100-40;o=false}else d.height=c.height+r;if(o&&(d.width>a[0]-t||d.height>a[1]-w))if(e.type=="image"||e.type=="swf"){t+=r;
|
||||
w+=r;o=Math.min(Math.min(a[0]-t,c.width)/c.width,Math.min(a[1]-w,c.height)/c.height);d.width=Math.round(o*(d.width-r))+r;d.height=Math.round(o*(d.height-r))+r}else{d.width=Math.min(d.width,a[0]-t);d.height=Math.min(d.height,a[1]-w)}d.top=a[3]+(a[1]-(d.height+40))*0.5;d.left=a[2]+(a[0]-(d.width+40))*0.5;if(c.autoScale===false){d.top=Math.max(a[3]+f,d.top);d.left=Math.max(a[2]+f,d.left)}return d},U=function(a){if(a&&a.length)switch(c.titlePosition){case "inside":return a;case "over":return'<span id="fancybox-title-over">'+
|
||||
a+"</span>";default:return'<span id="fancybox-title-wrap"><span id="fancybox-title-left"></span><span id="fancybox-title-main">'+a+'</span><span id="fancybox-title-right"></span></span>'}return false},V=function(){var a=c.title,d=l.width-c.padding*2,f="fancybox-title-"+c.titlePosition;b("#fancybox-title").remove();v=0;if(c.titleShow!==false){a=b.isFunction(c.titleFormat)?c.titleFormat(a,j,n,c):U(a);if(!(!a||a==="")){b('<div id="fancybox-title" class="'+f+'" />').css({width:d,paddingLeft:c.padding,
|
||||
paddingRight:c.padding}).html(a).appendTo("body");switch(c.titlePosition){case "inside":v=b("#fancybox-title").outerHeight(true)-c.padding;l.height+=v;break;case "over":b("#fancybox-title").css("bottom",c.padding);break;default:b("#fancybox-title").css("bottom",b("#fancybox-title").outerHeight(true)*-1);break}b("#fancybox-title").appendTo(D).hide()}}},W=function(){b(document).unbind("keydown.fb").bind("keydown.fb",function(a){if(a.keyCode==27&&c.enableEscapeButton){a.preventDefault();b.fancybox.close()}else if(a.keyCode==
|
||||
37){a.preventDefault();b.fancybox.prev()}else if(a.keyCode==39){a.preventDefault();b.fancybox.next()}});if(b.fn.mousewheel){g.unbind("mousewheel.fb");j.length>1&&g.bind("mousewheel.fb",function(a,d){a.preventDefault();h||d===0||(d>0?b.fancybox.prev():b.fancybox.next())})}if(c.showNavArrows){if(c.cyclic&&j.length>1||n!==0)A.show();if(c.cyclic&&j.length>1||n!=j.length-1)B.show()}},X=function(){var a,d;if(j.length-1>n){a=j[n+1].href;if(typeof a!=="undefined"&&a.match(G)){d=new Image;d.src=a}}if(n>0){a=
|
||||
j[n-1].href;if(typeof a!=="undefined"&&a.match(G)){d=new Image;d.src=a}}},L=function(){i.css("overflow",c.scrolling=="auto"?c.type=="image"||c.type=="iframe"||c.type=="swf"?"hidden":"auto":c.scrolling=="yes"?"auto":"visible");if(!b.support.opacity){i.get(0).style.removeAttribute("filter");g.get(0).style.removeAttribute("filter")}b("#fancybox-title").show();c.hideOnContentClick&&i.one("click",b.fancybox.close);c.hideOnOverlayClick&&x.one("click",b.fancybox.close);c.showCloseButton&&z.show();W();b(window).bind("resize.fb",
|
||||
b.fancybox.center);c.centerOnScroll?b(window).bind("scroll.fb",b.fancybox.center):b(window).unbind("scroll.fb");b.isFunction(c.onComplete)&&c.onComplete(j,n,c);h=false;X()},M=function(a){var d=Math.round(k.width+(l.width-k.width)*a),f=Math.round(k.height+(l.height-k.height)*a),o=Math.round(k.top+(l.top-k.top)*a),t=Math.round(k.left+(l.left-k.left)*a);g.css({width:d+"px",height:f+"px",top:o+"px",left:t+"px"});d=Math.max(d-c.padding*2,0);f=Math.max(f-(c.padding*2+v*a),0);i.css({width:d+"px",height:f+
|
||||
"px"});if(typeof l.opacity!=="undefined")g.css("opacity",a<0.5?0.5:a)},Y=function(a){var d=a.offset();d.top+=parseFloat(a.css("paddingTop"))||0;d.left+=parseFloat(a.css("paddingLeft"))||0;d.top+=parseFloat(a.css("border-top-width"))||0;d.left+=parseFloat(a.css("border-left-width"))||0;d.width=a.width();d.height=a.height();return d},Q=function(){var a=e.orig?b(e.orig):false,d={};if(a&&a.length){a=Y(a);d={width:a.width+c.padding*2,height:a.height+c.padding*2,top:a.top-c.padding-20,left:a.left-c.padding-
|
||||
20}}else{a=K();d={width:1,height:1,top:a[3]+a[1]*0.5,left:a[2]+a[0]*0.5}}return d},N=function(){u.hide();if(g.is(":visible")&&b.isFunction(c.onCleanup))if(c.onCleanup(j,n,c)===false){b.event.trigger("fancybox-cancel");h=false;return}j=q;n=p;c=e;i.get(0).scrollTop=0;i.get(0).scrollLeft=0;if(c.overlayShow){O&&b("select:not(#fancybox-tmp select)").filter(function(){return this.style.visibility!=="hidden"}).css({visibility:"hidden"}).one("fancybox-cleanup",function(){this.style.visibility="inherit"});
|
||||
x.css({"background-color":c.overlayColor,opacity:c.overlayOpacity}).unbind().show()}l=T();V();if(g.is(":visible")){b(z.add(A).add(B)).hide();var a=g.position(),d;k={top:a.top,left:a.left,width:g.width(),height:g.height()};d=k.width==l.width&&k.height==l.height;i.fadeOut(c.changeFade,function(){var f=function(){i.html(m.contents()).fadeIn(c.changeFade,L)};b.event.trigger("fancybox-change");i.empty().css("overflow","hidden");if(d){i.css({top:c.padding,left:c.padding,width:Math.max(l.width-c.padding*
|
||||
2,1),height:Math.max(l.height-c.padding*2-v,1)});f()}else{i.css({top:c.padding,left:c.padding,width:Math.max(k.width-c.padding*2,1),height:Math.max(k.height-c.padding*2,1)});y.prop=0;b(y).animate({prop:1},{duration:c.changeSpeed,easing:c.easingChange,step:M,complete:f})}})}else{g.css("opacity",1);if(c.transitionIn=="elastic"){k=Q();i.css({top:c.padding,left:c.padding,width:Math.max(k.width-c.padding*2,1),height:Math.max(k.height-c.padding*2,1)}).html(m.contents());g.css(k).show();if(c.opacity)l.opacity=
|
||||
0;y.prop=0;b(y).animate({prop:1},{duration:c.speedIn,easing:c.easingIn,step:M,complete:L})}else{i.css({top:c.padding,left:c.padding,width:Math.max(l.width-c.padding*2,1),height:Math.max(l.height-c.padding*2-v,1)}).html(m.contents());g.css(l).fadeIn(c.transitionIn=="none"?0:c.speedIn,L)}}},F=function(){m.width(e.width);m.height(e.height);if(e.width=="auto")e.width=m.width();if(e.height=="auto")e.height=m.height();N()},Z=function(){h=true;e.width=s.width;e.height=s.height;b("<img />").attr({id:"fancybox-img",
|
||||
src:s.src,alt:e.title}).appendTo(m);N()},C=function(){J();var a=q[p],d,f,o,t,w;e=b.extend({},b.fn.fancybox.defaults,typeof b(a).data("fancybox")=="undefined"?e:b(a).data("fancybox"));o=a.title||b(a).title||e.title||"";if(a.nodeName&&!e.orig)e.orig=b(a).children("img:first").length?b(a).children("img:first"):b(a);if(o===""&&e.orig)o=e.orig.attr("alt");d=a.nodeName&&/^(?:javascript|#)/i.test(a.href)?e.href||null:e.href||a.href||null;if(e.type){f=e.type;if(!d)d=e.content}else if(e.content)f="html";else if(d)if(d.match(G))f=
|
||||
"image";else if(d.match(S))f="swf";else if(b(a).hasClass("iframe"))f="iframe";else if(d.match(/#/)){a=d.substr(d.indexOf("#"));f=b(a).length>0?"inline":"ajax"}else f="ajax";else f="inline";e.type=f;e.href=d;e.title=o;if(e.autoDimensions&&e.type!=="iframe"&&e.type!=="swf"){e.width="auto";e.height="auto"}if(e.modal){e.overlayShow=true;e.hideOnOverlayClick=false;e.hideOnContentClick=false;e.enableEscapeButton=false;e.showCloseButton=false}if(b.isFunction(e.onStart))if(e.onStart(q,p,e)===false){h=false;
|
||||
return}m.css("padding",20+e.padding+e.margin);b(".fancybox-inline-tmp").unbind("fancybox-cancel").bind("fancybox-change",function(){b(this).replaceWith(i.children())});switch(f){case "html":m.html(e.content);F();break;case "inline":b('<div class="fancybox-inline-tmp" />').hide().insertBefore(b(a)).bind("fancybox-cleanup",function(){b(this).replaceWith(i.children())}).bind("fancybox-cancel",function(){b(this).replaceWith(m.children())});b(a).appendTo(m);F();break;case "image":h=false;b.fancybox.showActivity();
|
||||
s=new Image;s.onerror=function(){P()};s.onload=function(){s.onerror=null;s.onload=null;Z()};s.src=d;break;case "swf":t='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="'+e.width+'" height="'+e.height+'"><param name="movie" value="'+d+'"></param>';w="";b.each(e.swf,function(r,R){t+='<param name="'+r+'" value="'+R+'"></param>';w+=" "+r+'="'+R+'"'});t+='<embed src="'+d+'" type="application/x-shockwave-flash" width="'+e.width+'" height="'+e.height+'"'+w+"></embed></object>";m.html(t);
|
||||
F();break;case "ajax":a=d.split("#",2);f=e.ajax.data||{};if(a.length>1){d=a[0];if(typeof f=="string")f+="&selector="+a[1];else f.selector=a[1]}h=false;b.fancybox.showActivity();E=b.ajax(b.extend(e.ajax,{url:d,data:f,error:P,success:function(r){if(E.status==200){m.html(r);F()}}}));break;case "iframe":b('<iframe id="fancybox-frame" name="fancybox-frame'+(new Date).getTime()+'" frameborder="0" hspace="0" scrolling="'+e.scrolling+'" src="'+e.href+'"></iframe>').appendTo(m);N();break}},$=function(){if(u.is(":visible")){b("div",
|
||||
u).css("top",I*-40+"px");I=(I+1)%12}else clearInterval(H)},aa=function(){if(!b("#fancybox-wrap").length){b("body").append(m=b('<div id="fancybox-tmp"></div>'),u=b('<div id="fancybox-loading"><div></div></div>'),x=b('<div id="fancybox-overlay"></div>'),g=b('<div id="fancybox-wrap"></div>'));if(!b.support.opacity){g.addClass("fancybox-ie");u.addClass("fancybox-ie")}D=b('<div id="fancybox-outer"></div>').append('<div class="fancy-bg" id="fancy-bg-n"></div><div class="fancy-bg" id="fancy-bg-ne"></div><div class="fancy-bg" id="fancy-bg-e"></div><div class="fancy-bg" id="fancy-bg-se"></div><div class="fancy-bg" id="fancy-bg-s"></div><div class="fancy-bg" id="fancy-bg-sw"></div><div class="fancy-bg" id="fancy-bg-w"></div><div class="fancy-bg" id="fancy-bg-nw"></div>').appendTo(g);
|
||||
D.append(i=b('<div id="fancybox-inner"></div>'),z=b('<a id="fancybox-close"></a>'),A=b('<a href="javascript:;" id="fancybox-left"><span class="fancy-ico" id="fancybox-left-ico"></span></a>'),B=b('<a href="javascript:;" id="fancybox-right"><span class="fancy-ico" id="fancybox-right-ico"></span></a>'));z.click(b.fancybox.close);u.click(b.fancybox.cancel);A.click(function(a){a.preventDefault();b.fancybox.prev()});B.click(function(a){a.preventDefault();b.fancybox.next()});if(O){x.get(0).style.setExpression("height",
|
||||
"document.body.scrollHeight > document.body.offsetHeight ? document.body.scrollHeight : document.body.offsetHeight + 'px'");u.get(0).style.setExpression("top","(-20 + (document.documentElement.clientHeight ? document.documentElement.clientHeight/2 : document.body.clientHeight/2 ) + ( ignoreMe = document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop )) + 'px'");D.prepend('<iframe id="fancybox-hide-sel-frame" src="javascript:\'\';" scrolling="no" frameborder="0" ></iframe>')}}};
|
||||
b.fn.fancybox=function(a){b(this).data("fancybox",b.extend({},a,b.metadata?b(this).metadata():{})).unbind("click.fb").bind("click.fb",function(d){d.preventDefault();if(!h){h=true;b(this).blur();q=[];p=0;d=b(this).attr("rel")||"";if(!d||d==""||d==="nofollow")q.push(this);else{q=b("a[rel="+d+"], area[rel="+d+"]");p=q.index(this)}C();return false}});return this};b.fancybox=function(a,d){if(!h){h=true;d=typeof d!=="undefined"?d:{};q=[];p=d.index||0;if(b.isArray(a)){for(var f=0,o=a.length;f<o;f++)if(typeof a[f]==
|
||||
"object")b(a[f]).data("fancybox",b.extend({},d,a[f]));else a[f]=b({}).data("fancybox",b.extend({content:a[f]},d));q=jQuery.merge(q,a)}else{if(typeof a=="object")b(a).data("fancybox",b.extend({},d,a));else a=b({}).data("fancybox",b.extend({content:a},d));q.push(a)}if(p>q.length||p<0)p=0;C()}};b.fancybox.showActivity=function(){clearInterval(H);u.show();H=setInterval($,66)};b.fancybox.hideActivity=function(){u.hide()};b.fancybox.next=function(){return b.fancybox.pos(n+1)};b.fancybox.prev=function(){return b.fancybox.pos(n-
|
||||
1)};b.fancybox.pos=function(a){if(!h){a=parseInt(a,10);if(a>-1&&j.length>a){p=a;C()}if(c.cyclic&&j.length>1&&a<0){p=j.length-1;C()}if(c.cyclic&&j.length>1&&a>=j.length){p=0;C()}}};b.fancybox.cancel=function(){if(!h){h=true;b.event.trigger("fancybox-cancel");J();e&&b.isFunction(e.onCancel)&&e.onCancel(q,p,e);h=false}};b.fancybox.close=function(){function a(){x.fadeOut("fast");g.hide();b.event.trigger("fancybox-cleanup");i.empty();b.isFunction(c.onClosed)&&c.onClosed(j,n,c);j=e=[];n=p=0;c=e={};h=false}
|
||||
if(!(h||g.is(":hidden"))){h=true;if(c&&b.isFunction(c.onCleanup))if(c.onCleanup(j,n,c)===false){h=false;return}J();b(z.add(A).add(B)).hide();b("#fancybox-title").remove();g.add(i).add(x).unbind();b(window).unbind("resize.fb scroll.fb");b(document).unbind("keydown.fb");i.css("overflow","hidden");if(c.transitionOut=="elastic"){k=Q();var d=g.position();l={top:d.top,left:d.left,width:g.width(),height:g.height()};if(c.opacity)l.opacity=1;y.prop=1;b(y).animate({prop:0},{duration:c.speedOut,easing:c.easingOut,
|
||||
step:M,complete:a})}else g.fadeOut(c.transitionOut=="none"?0:c.speedOut,a)}};b.fancybox.resize=function(){var a,d;if(!(h||g.is(":hidden"))){h=true;a=i.wrapInner("<div style='overflow:auto'></div>").children();d=a.height();g.css({height:d+c.padding*2+v});i.css({height:d});a.replaceWith(a.children());b.fancybox.center()}};b.fancybox.center=function(){h=true;var a=K(),d=c.margin,f={};f.top=a[3]+(a[1]-(g.height()-v+40))*0.5;f.left=a[2]+(a[0]-(g.width()+40))*0.5;f.top=Math.max(a[3]+d,f.top);f.left=Math.max(a[2]+
|
||||
d,f.left);g.css(f);h=false};b.fn.fancybox.defaults={padding:10,margin:20,opacity:false,modal:false,cyclic:false,scrolling:"auto",width:560,height:340,autoScale:true,autoDimensions:true,centerOnScroll:false,ajax:{},swf:{wmode:"transparent"},hideOnOverlayClick:true,hideOnContentClick:false,overlayShow:true,overlayOpacity:0.3,overlayColor:"#666",titleShow:true,titlePosition:"outside",titleFormat:null,transitionIn:"fade",transitionOut:"fade",speedIn:300,speedOut:300,changeSpeed:300,changeFade:"fast",
|
||||
easingIn:"swing",easingOut:"swing",showCloseButton:true,showNavArrows:true,enableEscapeButton:true,onStart:null,onCancel:null,onComplete:null,onCleanup:null,onClosed:null};b(document).ready(function(){aa()})})(jQuery);
|
79
yii/assets/254ed3a0/js/main.js
Normal file
@ -0,0 +1,79 @@
|
||||
$(document).ready(function() {
|
||||
if($('div.form.login').length) { // in login page
|
||||
$('input#LoginForm_password').focus();
|
||||
}
|
||||
|
||||
$('table.preview input[name="checkAll"]').click(function() {
|
||||
$('table.preview .confirm input').prop('checked', this.checked);
|
||||
});
|
||||
|
||||
$('table.preview td.confirm input').click(function() {
|
||||
$('table.preview input[name="checkAll"]').prop('checked', !$('table.preview td.confirm input:not(:checked)').length);
|
||||
});
|
||||
$('table.preview input[name="checkAll"]').prop('checked', !$('table.preview td.confirm input:not(:checked)').length);
|
||||
|
||||
$('.form .row.sticky input:not(.error), .form .row.sticky select:not(.error), .form .row.sticky textarea:not(.error)').each(function(){
|
||||
var value;
|
||||
if(this.tagName=='SELECT')
|
||||
value=this.options[this.selectedIndex].text;
|
||||
else if(this.tagName=='TEXTAREA')
|
||||
value=$(this).html();
|
||||
else
|
||||
value=$(this).val();
|
||||
if(value=='')
|
||||
value='[empty]';
|
||||
$(this).before('<div class="value">'+value+'</div>').hide();
|
||||
});
|
||||
|
||||
$(document).on('click', '.form.gii .row.sticky .value', function(){
|
||||
$(this).hide();
|
||||
$(this).next().show().get(0).focus();
|
||||
});
|
||||
|
||||
|
||||
$('.form.gii .row input, .form.gii .row textarea, .form.gii .row select, .with-tooltip').not('.no-tooltip, .no-tooltip *').tooltip2({
|
||||
position: "center right",
|
||||
offset: [-2, 10]
|
||||
});
|
||||
|
||||
$('.form.gii .row input').change(function(){
|
||||
$('.form.gii .feedback').hide();
|
||||
$('.form.gii input[name="generate"]').hide();
|
||||
});
|
||||
|
||||
$('.form.gii .view-code').click(function(){
|
||||
var title=$(this).attr('rel');
|
||||
$.fancybox.showActivity();
|
||||
$.ajax({
|
||||
type: 'POST',
|
||||
cache: false,
|
||||
url: $(this).attr('href'),
|
||||
data: $('.form.gii form').serializeArray(),
|
||||
success: function(data){
|
||||
$.fancybox(data, {
|
||||
'title': title,
|
||||
'titlePosition': 'inside',
|
||||
'titleFormat': function(title, currentArray, currentIndex, currentOpts) {
|
||||
return '<div id="tip7-title"><span><a href="javascript:;" onclick="$.fancybox.close();">close</a></span>' + (title && title.length ? '<b>' + title + '</b>' : '' ) + '</div>';
|
||||
},
|
||||
'showCloseButton': false,
|
||||
'autoDimensions': false,
|
||||
'width': 900,
|
||||
'height': 'auto',
|
||||
'onComplete':function(){
|
||||
$('#fancybox-inner').scrollTop(0);
|
||||
}
|
||||
});
|
||||
},
|
||||
error: function(XMLHttpRequest, textStatus, errorThrown) {
|
||||
$.fancybox('<div class="error">'+XMLHttpRequest.responseText+'</div>');
|
||||
}
|
||||
});
|
||||
return false;
|
||||
});
|
||||
|
||||
$(document).on('click', '#fancybox-inner .close-code', function(){
|
||||
$.fancybox.close();
|
||||
return false;
|
||||
});
|
||||
});
|
364
yii/assets/254ed3a0/js/tooltip.js
Normal file
@ -0,0 +1,364 @@
|
||||
/**
|
||||
* CHANGES MADE BY YII DEVELOPERS, READ CAREFULLY BEFORE UPGRADING THIS FILE:
|
||||
* 1. This commit has been used:
|
||||
* https://github.com/jquerytools/jquerytools/commit/4f3f3f14e83b0ff276a795e9f45400930904adff#src/tooltip/tooltip.js
|
||||
* 2. Original `$.fn.tooltip` has been changed to `$.fn.tooltip2` to prevent conflict between jQuery UI Tooltip and
|
||||
* jQuery Tools Tooltip.
|
||||
*
|
||||
* @license
|
||||
* jQuery Tools @VERSION Tooltip - UI essentials
|
||||
*
|
||||
* NO COPYRIGHTS OR LICENSES. DO WHAT YOU LIKE.
|
||||
*
|
||||
* http://flowplayer.org/tools/tooltip/
|
||||
*
|
||||
* Since: November 2008
|
||||
* Date: @DATE
|
||||
*/
|
||||
(function($) {
|
||||
// static constructs
|
||||
$.tools = $.tools || {version: '@VERSION'};
|
||||
|
||||
$.tools.tooltip = {
|
||||
|
||||
conf: {
|
||||
|
||||
// default effect variables
|
||||
effect: 'toggle',
|
||||
fadeOutSpeed: "fast",
|
||||
predelay: 0,
|
||||
delay: 30,
|
||||
opacity: 1,
|
||||
tip: 0,
|
||||
fadeIE: false, // enables fade effect in IE
|
||||
|
||||
// 'top', 'bottom', 'right', 'left', 'center'
|
||||
position: ['top', 'center'],
|
||||
offset: [0, 0],
|
||||
relative: false,
|
||||
cancelDefault: true,
|
||||
|
||||
// type to event mapping
|
||||
events: {
|
||||
def: "mouseenter,mouseleave",
|
||||
input: "focus,blur",
|
||||
widget: "focus mouseenter,blur mouseleave",
|
||||
tooltip: "mouseenter,mouseleave"
|
||||
},
|
||||
|
||||
// 1.2
|
||||
layout: '<div/>',
|
||||
tipClass: 'tooltip'
|
||||
},
|
||||
|
||||
addEffect: function(name, loadFn, hideFn) {
|
||||
effects[name] = [loadFn, hideFn];
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
var effects = {
|
||||
toggle: [
|
||||
function(done) {
|
||||
var conf = this.getConf(), tip = this.getTip(), o = conf.opacity;
|
||||
if (o < 1) { tip.css({opacity: o}); }
|
||||
tip.show();
|
||||
done.call();
|
||||
},
|
||||
|
||||
function(done) {
|
||||
this.getTip().hide();
|
||||
done.call();
|
||||
}
|
||||
],
|
||||
|
||||
fade: [
|
||||
function(done) {
|
||||
var conf = this.getConf();
|
||||
if (!$.browser.msie || conf.fadeIE) {
|
||||
this.getTip().fadeTo(conf.fadeInSpeed, conf.opacity, done);
|
||||
}
|
||||
else {
|
||||
this.getTip().show();
|
||||
done();
|
||||
}
|
||||
},
|
||||
function(done) {
|
||||
var conf = this.getConf();
|
||||
if (!$.browser.msie || conf.fadeIE) {
|
||||
this.getTip().fadeOut(conf.fadeOutSpeed, done);
|
||||
}
|
||||
else {
|
||||
this.getTip().hide();
|
||||
done();
|
||||
}
|
||||
}
|
||||
]
|
||||
};
|
||||
|
||||
|
||||
/* calculate tip position relative to the trigger */
|
||||
function getPosition(trigger, tip, conf) {
|
||||
|
||||
|
||||
// get origin top/left position
|
||||
var top = conf.relative ? trigger.position().top : trigger.offset().top,
|
||||
left = conf.relative ? trigger.position().left : trigger.offset().left,
|
||||
pos = conf.position[0];
|
||||
|
||||
top -= tip.outerHeight() - conf.offset[0];
|
||||
left += trigger.outerWidth() + conf.offset[1];
|
||||
|
||||
// iPad position fix
|
||||
if (/iPad/i.test(navigator.userAgent)) {
|
||||
top -= $(window).scrollTop();
|
||||
}
|
||||
|
||||
// adjust Y
|
||||
var height = tip.outerHeight() + trigger.outerHeight();
|
||||
if (pos == 'center') { top += height / 2; }
|
||||
if (pos == 'bottom') { top += height; }
|
||||
|
||||
|
||||
// adjust X
|
||||
pos = conf.position[1];
|
||||
var width = tip.outerWidth() + trigger.outerWidth();
|
||||
if (pos == 'center') { left -= width / 2; }
|
||||
if (pos == 'left') { left -= width; }
|
||||
|
||||
return {top: top, left: left};
|
||||
}
|
||||
|
||||
|
||||
|
||||
function Tooltip(trigger, conf) {
|
||||
|
||||
var self = this,
|
||||
fire = trigger.add(self),
|
||||
tip,
|
||||
timer = 0,
|
||||
pretimer = 0,
|
||||
title = trigger.attr("title"),
|
||||
tipAttr = trigger.attr("data-tooltip"),
|
||||
effect = effects[conf.effect],
|
||||
shown,
|
||||
|
||||
// get show/hide configuration
|
||||
isInput = trigger.is(":input"),
|
||||
isWidget = isInput && trigger.is(":checkbox, :radio, select, :button, :submit"),
|
||||
type = trigger.attr("type"),
|
||||
evt = conf.events[type] || conf.events[isInput ? (isWidget ? 'widget' : 'input') : 'def'];
|
||||
|
||||
|
||||
// check that configuration is sane
|
||||
if (!effect) { throw "Nonexistent effect \"" + conf.effect + "\""; }
|
||||
|
||||
evt = evt.split(/,\s*/);
|
||||
if (evt.length != 2) { throw "Tooltip: bad events configuration for " + type; }
|
||||
|
||||
|
||||
// trigger --> show
|
||||
trigger.on(evt[0], function(e) {
|
||||
|
||||
clearTimeout(timer);
|
||||
if (conf.predelay) {
|
||||
pretimer = setTimeout(function() { self.show(e); }, conf.predelay);
|
||||
|
||||
} else {
|
||||
self.show(e);
|
||||
}
|
||||
|
||||
// trigger --> hide
|
||||
}).on(evt[1], function(e) {
|
||||
clearTimeout(pretimer);
|
||||
if (conf.delay) {
|
||||
timer = setTimeout(function() { self.hide(e); }, conf.delay);
|
||||
|
||||
} else {
|
||||
self.hide(e);
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
|
||||
// remove default title
|
||||
if (title && conf.cancelDefault) {
|
||||
trigger.removeAttr("title");
|
||||
trigger.data("title", title);
|
||||
}
|
||||
|
||||
$.extend(self, {
|
||||
|
||||
show: function(e) {
|
||||
|
||||
// tip not initialized yet
|
||||
if (!tip) {
|
||||
|
||||
// data-tooltip
|
||||
if (tipAttr) {
|
||||
tip = $(tipAttr);
|
||||
|
||||
// single tip element for all
|
||||
} else if (conf.tip) {
|
||||
tip = $(conf.tip).eq(0);
|
||||
|
||||
// autogenerated tooltip
|
||||
} else if (title) {
|
||||
tip = $(conf.layout).addClass(conf.tipClass).appendTo(document.body)
|
||||
.hide().append(title);
|
||||
|
||||
// manual tooltip
|
||||
} else {
|
||||
tip = trigger.next();
|
||||
if (!tip.length) { tip = trigger.parent().next(); }
|
||||
}
|
||||
|
||||
if (!tip.length) { throw "Cannot find tooltip for " + trigger; }
|
||||
}
|
||||
|
||||
if (self.isShown()) { return self; }
|
||||
|
||||
// stop previous animation
|
||||
tip.stop(true, true);
|
||||
|
||||
// get position
|
||||
var pos = getPosition(trigger, tip, conf);
|
||||
|
||||
// restore title for single tooltip element
|
||||
if (conf.tip) {
|
||||
tip.html(trigger.data("title"));
|
||||
}
|
||||
|
||||
// onBeforeShow
|
||||
e = $.Event();
|
||||
e.type = "onBeforeShow";
|
||||
fire.trigger(e, [pos]);
|
||||
if (e.isDefaultPrevented()) { return self; }
|
||||
|
||||
|
||||
// onBeforeShow may have altered the configuration
|
||||
pos = getPosition(trigger, tip, conf);
|
||||
|
||||
// set position
|
||||
tip.css({position:'absolute', top: pos.top, left: pos.left});
|
||||
|
||||
shown = true;
|
||||
|
||||
// invoke effect
|
||||
effect[0].call(self, function() {
|
||||
e.type = "onShow";
|
||||
shown = 'full';
|
||||
fire.trigger(e);
|
||||
});
|
||||
|
||||
|
||||
// tooltip events
|
||||
var event = conf.events.tooltip.split(/,\s*/);
|
||||
|
||||
if (!tip.data("__set")) {
|
||||
|
||||
tip.off(event[0]).on(event[0], function() {
|
||||
clearTimeout(timer);
|
||||
clearTimeout(pretimer);
|
||||
});
|
||||
|
||||
if (event[1] && !trigger.is("input:not(:checkbox, :radio), textarea")) {
|
||||
tip.off(event[1]).on(event[1], function(e) {
|
||||
|
||||
// being moved to the trigger element
|
||||
if (e.relatedTarget != trigger[0]) {
|
||||
trigger.trigger(evt[1].split(" ")[0]);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
// bind agein for if same tip element
|
||||
if (!conf.tip) tip.data("__set", true);
|
||||
}
|
||||
|
||||
return self;
|
||||
},
|
||||
|
||||
hide: function(e) {
|
||||
|
||||
if (!tip || !self.isShown()) { return self; }
|
||||
|
||||
// onBeforeHide
|
||||
e = $.Event();
|
||||
e.type = "onBeforeHide";
|
||||
fire.trigger(e);
|
||||
if (e.isDefaultPrevented()) { return; }
|
||||
|
||||
shown = false;
|
||||
|
||||
effects[conf.effect][1].call(self, function() {
|
||||
e.type = "onHide";
|
||||
fire.trigger(e);
|
||||
});
|
||||
|
||||
return self;
|
||||
},
|
||||
|
||||
isShown: function(fully) {
|
||||
return fully ? shown == 'full' : shown;
|
||||
},
|
||||
|
||||
getConf: function() {
|
||||
return conf;
|
||||
},
|
||||
|
||||
getTip: function() {
|
||||
return tip;
|
||||
},
|
||||
|
||||
getTrigger: function() {
|
||||
return trigger;
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
// callbacks
|
||||
$.each("onHide,onBeforeShow,onShow,onBeforeHide".split(","), function(i, name) {
|
||||
|
||||
// configuration
|
||||
if ($.isFunction(conf[name])) {
|
||||
$(self).on(name, conf[name]);
|
||||
}
|
||||
|
||||
// API
|
||||
self[name] = function(fn) {
|
||||
if (fn) { $(self).on(name, fn); }
|
||||
return self;
|
||||
};
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
|
||||
// jQuery plugin implementation
|
||||
$.fn.tooltip2 = function(conf) {
|
||||
|
||||
// return existing instance
|
||||
var api = this.data("tooltip");
|
||||
if (api) { return api; }
|
||||
|
||||
conf = $.extend(true, {}, $.tools.tooltip.conf, conf);
|
||||
|
||||
// position can also be given as string
|
||||
if (typeof conf.position == 'string') {
|
||||
conf.position = conf.position.split(/,?\s/);
|
||||
}
|
||||
|
||||
// install tooltip for each entry in jQuery object
|
||||
this.each(function() {
|
||||
api = new Tooltip($(this), conf);
|
||||
$(this).data("tooltip", api);
|
||||
});
|
||||
|
||||
return conf.api ? api: this;
|
||||
};
|
||||
|
||||
}) (jQuery);
|
||||
|
||||
|
||||
|
BIN
yii/assets/7b3570a4/autocomplete/indicator.gif
Normal file
After Width: | Height: | Size: 1.5 KiB |
48
yii/assets/7b3570a4/autocomplete/jquery.autocomplete.css
Normal file
@ -0,0 +1,48 @@
|
||||
.ac_results {
|
||||
padding: 0px;
|
||||
border: 1px solid black;
|
||||
background-color: white;
|
||||
overflow: hidden;
|
||||
z-index: 99999;
|
||||
}
|
||||
|
||||
.ac_results ul {
|
||||
width: 100%;
|
||||
list-style-position: outside;
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.ac_results li {
|
||||
margin: 0px;
|
||||
padding: 2px 5px;
|
||||
cursor: default;
|
||||
display: block;
|
||||
/*
|
||||
if width will be 100% horizontal scrollbar will apear
|
||||
when scroll mode will be used
|
||||
*/
|
||||
/*width: 100%;*/
|
||||
font: menu;
|
||||
font-size: 12px;
|
||||
/*
|
||||
it is very important, if line-height not setted or setted
|
||||
in relative units scroll will be broken in firefox
|
||||
*/
|
||||
line-height: 16px;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.ac_loading {
|
||||
background: white url('indicator.gif') right center no-repeat;
|
||||
}
|
||||
|
||||
.ac_odd {
|
||||
background-color: #eee;
|
||||
}
|
||||
|
||||
.ac_over {
|
||||
background-color: #0A246A;
|
||||
color: white;
|
||||
}
|
116
yii/assets/7b3570a4/jquery.ajaxqueue.js
Normal file
@ -0,0 +1,116 @@
|
||||
/**
|
||||
* Ajax Queue Plugin
|
||||
*
|
||||
* Homepage: http://jquery.com/plugins/project/ajaxqueue
|
||||
* Documentation: http://docs.jquery.com/AjaxQueue
|
||||
*/
|
||||
|
||||
/**
|
||||
|
||||
<script>
|
||||
$(function(){
|
||||
jQuery.ajaxQueue({
|
||||
url: "test.php",
|
||||
success: function(html){ jQuery("ul").append(html); }
|
||||
});
|
||||
jQuery.ajaxQueue({
|
||||
url: "test.php",
|
||||
success: function(html){ jQuery("ul").append(html); }
|
||||
});
|
||||
jQuery.ajaxSync({
|
||||
url: "test.php",
|
||||
success: function(html){ jQuery("ul").append("<b>"+html+"</b>"); }
|
||||
});
|
||||
jQuery.ajaxSync({
|
||||
url: "test.php",
|
||||
success: function(html){ jQuery("ul").append("<b>"+html+"</b>"); }
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<ul style="position: absolute; top: 5px; right: 5px;"></ul>
|
||||
|
||||
*/
|
||||
/*
|
||||
* Queued Ajax requests.
|
||||
* A new Ajax request won't be started until the previous queued
|
||||
* request has finished.
|
||||
*/
|
||||
|
||||
/*
|
||||
* Synced Ajax requests.
|
||||
* The Ajax request will happen as soon as you call this method, but
|
||||
* the callbacks (success/error/complete) won't fire until all previous
|
||||
* synced requests have been completed.
|
||||
*/
|
||||
|
||||
|
||||
(function($) {
|
||||
|
||||
var ajax = $.ajax;
|
||||
|
||||
var pendingRequests = {};
|
||||
|
||||
var synced = [];
|
||||
var syncedData = [];
|
||||
|
||||
$.ajax = function(settings) {
|
||||
// create settings for compatibility with ajaxSetup
|
||||
settings = jQuery.extend(settings, jQuery.extend({}, jQuery.ajaxSettings, settings));
|
||||
|
||||
var port = settings.port;
|
||||
|
||||
switch(settings.mode) {
|
||||
case "abort":
|
||||
if ( pendingRequests[port] ) {
|
||||
pendingRequests[port].abort();
|
||||
}
|
||||
return pendingRequests[port] = ajax.apply(this, arguments);
|
||||
case "queue":
|
||||
var _old = settings.complete;
|
||||
settings.complete = function(){
|
||||
if ( _old )
|
||||
_old.apply( this, arguments );
|
||||
jQuery([ajax]).dequeue("ajax" + port );;
|
||||
};
|
||||
|
||||
jQuery([ ajax ]).queue("ajax" + port, function(){
|
||||
ajax( settings );
|
||||
});
|
||||
return;
|
||||
case "sync":
|
||||
var pos = synced.length;
|
||||
|
||||
synced[ pos ] = {
|
||||
error: settings.error,
|
||||
success: settings.success,
|
||||
complete: settings.complete,
|
||||
done: false
|
||||
};
|
||||
|
||||
syncedData[ pos ] = {
|
||||
error: [],
|
||||
success: [],
|
||||
complete: []
|
||||
};
|
||||
|
||||
settings.error = function(){ syncedData[ pos ].error = arguments; };
|
||||
settings.success = function(){ syncedData[ pos ].success = arguments; };
|
||||
settings.complete = function(){
|
||||
syncedData[ pos ].complete = arguments;
|
||||
synced[ pos ].done = true;
|
||||
|
||||
if ( pos == 0 || !synced[ pos-1 ] )
|
||||
for ( var i = pos; i < synced.length && synced[i].done; i++ ) {
|
||||
if ( synced[i].error ) synced[i].error.apply( jQuery, syncedData[i].error );
|
||||
if ( synced[i].success ) synced[i].success.apply( jQuery, syncedData[i].success );
|
||||
if ( synced[i].complete ) synced[i].complete.apply( jQuery, syncedData[i].complete );
|
||||
|
||||
synced[i] = null;
|
||||
syncedData[i] = null;
|
||||
}
|
||||
};
|
||||
}
|
||||
return ajax.apply(this, arguments);
|
||||
};
|
||||
|
||||
})(jQuery);
|
813
yii/assets/7b3570a4/jquery.autocomplete.js
Normal file
@ -0,0 +1,813 @@
|
||||
/*
|
||||
* jQuery Autocomplete plugin 1.1
|
||||
*
|
||||
* Modified for Yii Framework:
|
||||
* - Renamed "autocomplete" to "legacyautocomplete".
|
||||
* - Fixed IE8 problems (mario.ffranco).
|
||||
*
|
||||
* Copyright (c) 2009 Jörn Zaefferer
|
||||
*
|
||||
* Dual licensed under the MIT and GPL licenses:
|
||||
* http://www.opensource.org/licenses/mit-license.php
|
||||
* http://www.gnu.org/licenses/gpl.html
|
||||
*
|
||||
* Revision: $Id: jquery.autocomplete.js 15 2009-08-22 10:30:27Z joern.zaefferer $
|
||||
*/
|
||||
|
||||
;(function($) {
|
||||
|
||||
$.fn.extend({
|
||||
legacyautocomplete: function(urlOrData, options) {
|
||||
var isUrl = typeof urlOrData == "string";
|
||||
options = $.extend({}, $.Autocompleter.defaults, {
|
||||
url: isUrl ? urlOrData : null,
|
||||
data: isUrl ? null : urlOrData,
|
||||
delay: isUrl ? $.Autocompleter.defaults.delay : 10,
|
||||
max: options && !options.scroll ? 10 : 150
|
||||
}, options);
|
||||
|
||||
// if highlight is set to false, replace it with a do-nothing function
|
||||
options.highlight = options.highlight || function(value) { return value; };
|
||||
|
||||
// if the formatMatch option is not specified, then use formatItem for backwards compatibility
|
||||
options.formatMatch = options.formatMatch || options.formatItem;
|
||||
|
||||
return this.each(function() {
|
||||
new $.Autocompleter(this, options);
|
||||
});
|
||||
},
|
||||
result: function(handler) {
|
||||
return this.bind("result", handler);
|
||||
},
|
||||
search: function(handler) {
|
||||
return this.trigger("search", [handler]);
|
||||
},
|
||||
flushCache: function() {
|
||||
return this.trigger("flushCache");
|
||||
},
|
||||
setOptions: function(options){
|
||||
return this.trigger("setOptions", [options]);
|
||||
},
|
||||
unautocomplete: function() {
|
||||
return this.trigger("unautocomplete");
|
||||
}
|
||||
});
|
||||
|
||||
$.Autocompleter = function(input, options) {
|
||||
|
||||
var KEY = {
|
||||
UP: 38,
|
||||
DOWN: 40,
|
||||
DEL: 46,
|
||||
TAB: 9,
|
||||
RETURN: 13,
|
||||
ESC: 27,
|
||||
COMMA: 188,
|
||||
PAGEUP: 33,
|
||||
PAGEDOWN: 34,
|
||||
BACKSPACE: 8
|
||||
};
|
||||
|
||||
// Create $ object for input element
|
||||
var $input = $(input).attr("autocomplete", "off").addClass(options.inputClass);
|
||||
|
||||
var timeout;
|
||||
var previousValue = "";
|
||||
var cache = $.Autocompleter.Cache(options);
|
||||
var hasFocus = 0;
|
||||
var lastKeyPressCode;
|
||||
var config = {
|
||||
mouseDownOnSelect: false
|
||||
};
|
||||
var select = $.Autocompleter.Select(options, input, selectCurrent, config);
|
||||
|
||||
var blockSubmit;
|
||||
|
||||
// prevent form submit in opera when selecting with return key
|
||||
$.browser.opera && $(input.form).bind("submit.autocomplete", function() {
|
||||
if (blockSubmit) {
|
||||
blockSubmit = false;
|
||||
return false;
|
||||
}
|
||||
});
|
||||
|
||||
// only opera doesn't trigger keydown multiple times while pressed, others don't work with keypress at all
|
||||
$input.bind(($.browser.opera ? "keypress" : "keydown") + ".autocomplete", function(event) {
|
||||
// a keypress means the input has focus
|
||||
// avoids issue where input had focus before the autocomplete was applied
|
||||
hasFocus = 1;
|
||||
// track last key pressed
|
||||
lastKeyPressCode = event.keyCode;
|
||||
switch(event.keyCode) {
|
||||
|
||||
case KEY.UP:
|
||||
event.preventDefault();
|
||||
if ( select.visible() ) {
|
||||
select.prev();
|
||||
} else {
|
||||
onChange(0, true);
|
||||
}
|
||||
break;
|
||||
|
||||
case KEY.DOWN:
|
||||
event.preventDefault();
|
||||
if ( select.visible() ) {
|
||||
select.next();
|
||||
} else {
|
||||
onChange(0, true);
|
||||
}
|
||||
break;
|
||||
|
||||
case KEY.PAGEUP:
|
||||
event.preventDefault();
|
||||
if ( select.visible() ) {
|
||||
select.pageUp();
|
||||
} else {
|
||||
onChange(0, true);
|
||||
}
|
||||
break;
|
||||
|
||||
case KEY.PAGEDOWN:
|
||||
event.preventDefault();
|
||||
if ( select.visible() ) {
|
||||
select.pageDown();
|
||||
} else {
|
||||
onChange(0, true);
|
||||
}
|
||||
break;
|
||||
|
||||
// matches also semicolon
|
||||
case options.multiple && $.trim(options.multipleSeparator) == "," && KEY.COMMA:
|
||||
case KEY.TAB:
|
||||
case KEY.RETURN:
|
||||
if( selectCurrent() ) {
|
||||
// stop default to prevent a form submit, Opera needs special handling
|
||||
event.preventDefault();
|
||||
blockSubmit = true;
|
||||
return false;
|
||||
}
|
||||
break;
|
||||
|
||||
case KEY.ESC:
|
||||
select.hide();
|
||||
break;
|
||||
|
||||
default:
|
||||
clearTimeout(timeout);
|
||||
timeout = setTimeout(onChange, options.delay);
|
||||
break;
|
||||
}
|
||||
}).focus(function(){
|
||||
// track whether the field has focus, we shouldn't process any
|
||||
// results if the field no longer has focus
|
||||
hasFocus++;
|
||||
}).blur(function() {
|
||||
hasFocus = 0;
|
||||
if (!config.mouseDownOnSelect) {
|
||||
hideResults();
|
||||
}
|
||||
}).click(function() {
|
||||
// show select when clicking in a focused field
|
||||
if ( hasFocus++ > 1 && !select.visible() ) {
|
||||
onChange(0, true);
|
||||
}
|
||||
}).bind("search", function() {
|
||||
// TODO why not just specifying both arguments?
|
||||
var fn = (arguments.length > 1) ? arguments[1] : null;
|
||||
function findValueCallback(q, data) {
|
||||
var result;
|
||||
if( data && data.length ) {
|
||||
for (var i=0; i < data.length; i++) {
|
||||
if( data[i].result.toLowerCase() == q.toLowerCase() ) {
|
||||
result = data[i];
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
if( typeof fn == "function" ) fn(result);
|
||||
else $input.trigger("result", result && [result.data, result.value]);
|
||||
}
|
||||
$.each(trimWords($input.val()), function(i, value) {
|
||||
request(value, findValueCallback, findValueCallback);
|
||||
});
|
||||
}).bind("flushCache", function() {
|
||||
cache.flush();
|
||||
}).bind("setOptions", function() {
|
||||
$.extend(options, arguments[1]);
|
||||
// if we've updated the data, repopulate
|
||||
if ( "data" in arguments[1] )
|
||||
cache.populate();
|
||||
}).bind("unautocomplete", function() {
|
||||
select.unbind();
|
||||
$input.unbind();
|
||||
$(input.form).unbind(".autocomplete");
|
||||
});
|
||||
|
||||
|
||||
function selectCurrent() {
|
||||
var selected = select.selected();
|
||||
if( !selected )
|
||||
return false;
|
||||
|
||||
var v = selected.result;
|
||||
previousValue = v;
|
||||
|
||||
if ( options.multiple ) {
|
||||
var words = trimWords($input.val());
|
||||
if ( words.length > 1 ) {
|
||||
var seperator = options.multipleSeparator.length;
|
||||
var cursorAt = $(input).selection().start;
|
||||
var wordAt, progress = 0;
|
||||
$.each(words, function(i, word) {
|
||||
progress += word.length;
|
||||
if (cursorAt <= progress) {
|
||||
wordAt = i;
|
||||
// Following return caused IE8 to set cursor to the start of the line.
|
||||
// return false;
|
||||
}
|
||||
progress += seperator;
|
||||
});
|
||||
words[wordAt] = v;
|
||||
// TODO this should set the cursor to the right position, but it gets overriden somewhere
|
||||
//$.Autocompleter.Selection(input, progress + seperator, progress + seperator);
|
||||
v = words.join( options.multipleSeparator );
|
||||
}
|
||||
v += options.multipleSeparator;
|
||||
}
|
||||
|
||||
$input.val(v);
|
||||
hideResultsNow();
|
||||
$input.trigger("result", [selected.data, selected.value]);
|
||||
return true;
|
||||
}
|
||||
|
||||
function onChange(crap, skipPrevCheck) {
|
||||
if( lastKeyPressCode == KEY.DEL ) {
|
||||
select.hide();
|
||||
return;
|
||||
}
|
||||
|
||||
var currentValue = $input.val();
|
||||
|
||||
if ( !skipPrevCheck && currentValue == previousValue )
|
||||
return;
|
||||
|
||||
previousValue = currentValue;
|
||||
|
||||
currentValue = lastWord(currentValue);
|
||||
if ( currentValue.length >= options.minChars) {
|
||||
$input.addClass(options.loadingClass);
|
||||
if (!options.matchCase)
|
||||
currentValue = currentValue.toLowerCase();
|
||||
request(currentValue, receiveData, hideResultsNow);
|
||||
} else {
|
||||
stopLoading();
|
||||
select.hide();
|
||||
}
|
||||
};
|
||||
|
||||
function trimWords(value) {
|
||||
if (!value)
|
||||
return [""];
|
||||
if (!options.multiple)
|
||||
return [$.trim(value)];
|
||||
return $.map(value.split(options.multipleSeparator), function(word) {
|
||||
return $.trim(value).length ? $.trim(word) : null;
|
||||
});
|
||||
}
|
||||
|
||||
function lastWord(value) {
|
||||
if ( !options.multiple )
|
||||
return value;
|
||||
var words = trimWords(value);
|
||||
if (words.length == 1)
|
||||
return words[0];
|
||||
var cursorAt = $(input).selection().start;
|
||||
if (cursorAt == value.length) {
|
||||
words = trimWords(value)
|
||||
} else {
|
||||
words = trimWords(value.replace(value.substring(cursorAt), ""));
|
||||
}
|
||||
return words[words.length - 1];
|
||||
}
|
||||
|
||||
// fills in the input box w/the first match (assumed to be the best match)
|
||||
// q: the term entered
|
||||
// sValue: the first matching result
|
||||
function autoFill(q, sValue){
|
||||
// autofill in the complete box w/the first match as long as the user hasn't entered in more data
|
||||
// if the last user key pressed was backspace, don't autofill
|
||||
if( options.autoFill && (lastWord($input.val()).toLowerCase() == q.toLowerCase()) && lastKeyPressCode != KEY.BACKSPACE ) {
|
||||
// fill in the value (keep the case the user has typed)
|
||||
$input.val($input.val() + sValue.substring(lastWord(previousValue).length));
|
||||
// select the portion of the value not typed by the user (so the next character will erase)
|
||||
$(input).selection(previousValue.length, previousValue.length + sValue.length);
|
||||
}
|
||||
};
|
||||
|
||||
function hideResults() {
|
||||
clearTimeout(timeout);
|
||||
timeout = setTimeout(hideResultsNow, 200);
|
||||
};
|
||||
|
||||
function hideResultsNow() {
|
||||
var wasVisible = select.visible();
|
||||
select.hide();
|
||||
clearTimeout(timeout);
|
||||
stopLoading();
|
||||
if (options.mustMatch) {
|
||||
// call search and run callback
|
||||
$input.search(
|
||||
function (result){
|
||||
// if no value found, clear the input box
|
||||
if( !result ) {
|
||||
if (options.multiple) {
|
||||
var words = trimWords($input.val()).slice(0, -1);
|
||||
$input.val( words.join(options.multipleSeparator) + (words.length ? options.multipleSeparator : "") );
|
||||
}
|
||||
else {
|
||||
$input.val( "" );
|
||||
$input.trigger("result", null);
|
||||
}
|
||||
}
|
||||
}
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
function receiveData(q, data) {
|
||||
if ( data && data.length && hasFocus ) {
|
||||
stopLoading();
|
||||
select.display(data, q);
|
||||
autoFill(q, data[0].value);
|
||||
select.show();
|
||||
} else {
|
||||
hideResultsNow();
|
||||
}
|
||||
};
|
||||
|
||||
function request(term, success, failure) {
|
||||
if (!options.matchCase)
|
||||
term = term.toLowerCase();
|
||||
var data = cache.load(term);
|
||||
// recieve the cached data
|
||||
if (data && data.length) {
|
||||
success(term, data);
|
||||
// if an AJAX url has been supplied, try loading the data now
|
||||
} else if( (typeof options.url == "string") && (options.url.length > 0) ){
|
||||
|
||||
var extraParams = {
|
||||
timestamp: +new Date()
|
||||
};
|
||||
$.each(options.extraParams, function(key, param) {
|
||||
extraParams[key] = typeof param == "function" ? param() : param;
|
||||
});
|
||||
|
||||
$.ajax({
|
||||
// try to leverage ajaxQueue plugin to abort previous requests
|
||||
mode: "abort",
|
||||
// limit abortion to this input
|
||||
port: "autocomplete" + input.name,
|
||||
dataType: options.dataType,
|
||||
url: options.url,
|
||||
data: $.extend({
|
||||
q: lastWord(term),
|
||||
limit: options.max
|
||||
}, extraParams),
|
||||
success: function(data) {
|
||||
var parsed = options.parse && options.parse(data) || parse(data);
|
||||
cache.add(term, parsed);
|
||||
success(term, parsed);
|
||||
}
|
||||
});
|
||||
} else {
|
||||
// if we have a failure, we need to empty the list -- this prevents the the [TAB] key from selecting the last successful match
|
||||
select.emptyList();
|
||||
failure(term);
|
||||
}
|
||||
};
|
||||
|
||||
function parse(data) {
|
||||
var parsed = [];
|
||||
var rows = data.split("\n");
|
||||
for (var i=0; i < rows.length; i++) {
|
||||
var row = $.trim(rows[i]);
|
||||
if (row) {
|
||||
row = row.split("|");
|
||||
parsed[parsed.length] = {
|
||||
data: row,
|
||||
value: row[0],
|
||||
result: options.formatResult && options.formatResult(row, row[0]) || row[0]
|
||||
};
|
||||
}
|
||||
}
|
||||
return parsed;
|
||||
};
|
||||
|
||||
function stopLoading() {
|
||||
$input.removeClass(options.loadingClass);
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
$.Autocompleter.defaults = {
|
||||
inputClass: "ac_input",
|
||||
resultsClass: "ac_results",
|
||||
loadingClass: "ac_loading",
|
||||
minChars: 1,
|
||||
delay: 400,
|
||||
matchCase: false,
|
||||
matchSubset: true,
|
||||
matchContains: false,
|
||||
cacheLength: 10,
|
||||
max: 100,
|
||||
mustMatch: false,
|
||||
extraParams: {},
|
||||
selectFirst: true,
|
||||
formatItem: function(row) { return row[0]; },
|
||||
formatMatch: null,
|
||||
autoFill: false,
|
||||
width: 0,
|
||||
multiple: false,
|
||||
multipleSeparator: ", ",
|
||||
highlight: function(value, term) {
|
||||
return value.replace(new RegExp("(?![^&;]+;)(?!<[^<>]*)(" + term.replace(/([\^\$\(\)\[\]\{\}\*\.\+\?\|\\])/gi, "\\$1") + ")(?![^<>]*>)(?![^&;]+;)", "gi"), "<strong>$1</strong>");
|
||||
},
|
||||
scroll: true,
|
||||
scrollHeight: 180
|
||||
};
|
||||
|
||||
$.Autocompleter.Cache = function(options) {
|
||||
|
||||
var data = {};
|
||||
var length = 0;
|
||||
|
||||
function matchSubset(s, sub) {
|
||||
if (!options.matchCase)
|
||||
s = s.toLowerCase();
|
||||
var i = s.indexOf(sub);
|
||||
if (options.matchContains == "word"){
|
||||
i = s.toLowerCase().search("\\b" + sub.toLowerCase());
|
||||
}
|
||||
if (i == -1) return false;
|
||||
return i == 0 || options.matchContains;
|
||||
};
|
||||
|
||||
function add(q, value) {
|
||||
if (length > options.cacheLength){
|
||||
flush();
|
||||
}
|
||||
if (!data[q]){
|
||||
length++;
|
||||
}
|
||||
data[q] = value;
|
||||
}
|
||||
|
||||
function populate(){
|
||||
if( !options.data ) return false;
|
||||
// track the matches
|
||||
var stMatchSets = {},
|
||||
nullData = 0;
|
||||
|
||||
// no url was specified, we need to adjust the cache length to make sure it fits the local data store
|
||||
if( !options.url ) options.cacheLength = 1;
|
||||
|
||||
// track all options for minChars = 0
|
||||
stMatchSets[""] = [];
|
||||
|
||||
// loop through the array and create a lookup structure
|
||||
for ( var i = 0, ol = options.data.length; i < ol; i++ ) {
|
||||
var rawValue = options.data[i];
|
||||
// if rawValue is a string, make an array otherwise just reference the array
|
||||
rawValue = (typeof rawValue == "string") ? [rawValue] : rawValue;
|
||||
|
||||
var value = options.formatMatch(rawValue, i+1, options.data.length);
|
||||
if ( value === false )
|
||||
continue;
|
||||
|
||||
var firstChar = value.charAt(0).toLowerCase();
|
||||
// if no lookup array for this character exists, look it up now
|
||||
if( !stMatchSets[firstChar] )
|
||||
stMatchSets[firstChar] = [];
|
||||
|
||||
// if the match is a string
|
||||
var row = {
|
||||
value: value,
|
||||
data: rawValue,
|
||||
result: options.formatResult && options.formatResult(rawValue) || value
|
||||
};
|
||||
|
||||
// push the current match into the set list
|
||||
stMatchSets[firstChar].push(row);
|
||||
|
||||
// keep track of minChars zero items
|
||||
if ( nullData++ < options.max ) {
|
||||
stMatchSets[""].push(row);
|
||||
}
|
||||
};
|
||||
|
||||
// add the data items to the cache
|
||||
$.each(stMatchSets, function(i, value) {
|
||||
// increase the cache size
|
||||
options.cacheLength++;
|
||||
// add to the cache
|
||||
add(i, value);
|
||||
});
|
||||
}
|
||||
|
||||
// populate any existing data
|
||||
setTimeout(populate, 25);
|
||||
|
||||
function flush(){
|
||||
data = {};
|
||||
length = 0;
|
||||
}
|
||||
|
||||
return {
|
||||
flush: flush,
|
||||
add: add,
|
||||
populate: populate,
|
||||
load: function(q) {
|
||||
if (!options.cacheLength || !length)
|
||||
return null;
|
||||
/*
|
||||
* if dealing w/local data and matchContains than we must make sure
|
||||
* to loop through all the data collections looking for matches
|
||||
*/
|
||||
if( !options.url && options.matchContains ){
|
||||
// track all matches
|
||||
var csub = [];
|
||||
// loop through all the data grids for matches
|
||||
for( var k in data ){
|
||||
// don't search through the stMatchSets[""] (minChars: 0) cache
|
||||
// this prevents duplicates
|
||||
if( k.length > 0 ){
|
||||
var c = data[k];
|
||||
$.each(c, function(i, x) {
|
||||
// if we've got a match, add it to the array
|
||||
if (matchSubset(x.value, q)) {
|
||||
csub.push(x);
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
return csub;
|
||||
} else
|
||||
// if the exact item exists, use it
|
||||
if (data[q]){
|
||||
return data[q];
|
||||
} else
|
||||
if (options.matchSubset) {
|
||||
for (var i = q.length - 1; i >= options.minChars; i--) {
|
||||
var c = data[q.substr(0, i)];
|
||||
if (c) {
|
||||
var csub = [];
|
||||
$.each(c, function(i, x) {
|
||||
if (matchSubset(x.value, q)) {
|
||||
csub[csub.length] = x;
|
||||
}
|
||||
});
|
||||
return csub;
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
$.Autocompleter.Select = function (options, input, select, config) {
|
||||
var CLASSES = {
|
||||
ACTIVE: "ac_over"
|
||||
};
|
||||
|
||||
var listItems,
|
||||
active = -1,
|
||||
data,
|
||||
term = "",
|
||||
needsInit = true,
|
||||
element,
|
||||
list;
|
||||
|
||||
// Create results
|
||||
function init() {
|
||||
if (!needsInit)
|
||||
return;
|
||||
element = $("<div/>")
|
||||
.hide()
|
||||
.addClass(options.resultsClass)
|
||||
.css("position", "absolute")
|
||||
.appendTo(document.body);
|
||||
|
||||
list = $("<ul/>").appendTo(element).mouseover( function(event) {
|
||||
if(target(event).nodeName && target(event).nodeName.toUpperCase() == 'LI') {
|
||||
active = $("li", list).removeClass(CLASSES.ACTIVE).index(target(event));
|
||||
$(target(event)).addClass(CLASSES.ACTIVE);
|
||||
}
|
||||
}).click(function(event) {
|
||||
$(target(event)).addClass(CLASSES.ACTIVE);
|
||||
select();
|
||||
// TODO provide option to avoid setting focus again after selection? useful for cleanup-on-focus
|
||||
input.focus();
|
||||
return false;
|
||||
}).mousedown(function() {
|
||||
config.mouseDownOnSelect = true;
|
||||
}).mouseup(function() {
|
||||
config.mouseDownOnSelect = false;
|
||||
});
|
||||
|
||||
if( options.width > 0 )
|
||||
element.css("width", options.width);
|
||||
|
||||
needsInit = false;
|
||||
}
|
||||
|
||||
function target(event) {
|
||||
var element = event.target;
|
||||
while(element && element.tagName != "LI")
|
||||
element = element.parentNode;
|
||||
// more fun with IE, sometimes event.target is empty, just ignore it then
|
||||
if(!element)
|
||||
return [];
|
||||
return element;
|
||||
}
|
||||
|
||||
function moveSelect(step) {
|
||||
listItems.slice(active, active + 1).removeClass(CLASSES.ACTIVE);
|
||||
movePosition(step);
|
||||
var activeItem = listItems.slice(active, active + 1).addClass(CLASSES.ACTIVE);
|
||||
if(options.scroll) {
|
||||
var offset = 0;
|
||||
listItems.slice(0, active).each(function() {
|
||||
offset += this.offsetHeight;
|
||||
});
|
||||
if((offset + activeItem[0].offsetHeight - list.scrollTop()) > list[0].clientHeight) {
|
||||
list.scrollTop(offset + activeItem[0].offsetHeight - list.innerHeight());
|
||||
} else if(offset < list.scrollTop()) {
|
||||
list.scrollTop(offset);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
function movePosition(step) {
|
||||
active += step;
|
||||
if (active < 0) {
|
||||
active = listItems.size() - 1;
|
||||
} else if (active >= listItems.size()) {
|
||||
active = 0;
|
||||
}
|
||||
}
|
||||
|
||||
function limitNumberOfItems(available) {
|
||||
return options.max && options.max < available
|
||||
? options.max
|
||||
: available;
|
||||
}
|
||||
|
||||
function fillList() {
|
||||
list.empty();
|
||||
var max = limitNumberOfItems(data.length);
|
||||
for (var i=0; i < max; i++) {
|
||||
if (!data[i])
|
||||
continue;
|
||||
var formatted = options.formatItem(data[i].data, i+1, max, data[i].value, term);
|
||||
if ( formatted === false )
|
||||
continue;
|
||||
var li = $("<li/>").html( options.highlight(formatted, term) ).addClass(i%2 == 0 ? "ac_even" : "ac_odd").appendTo(list)[0];
|
||||
$.data(li, "ac_data", data[i]);
|
||||
}
|
||||
listItems = list.find("li");
|
||||
if ( options.selectFirst ) {
|
||||
listItems.slice(0, 1).addClass(CLASSES.ACTIVE);
|
||||
active = 0;
|
||||
}
|
||||
// apply bgiframe if available
|
||||
if ( $.fn.bgiframe )
|
||||
list.bgiframe();
|
||||
}
|
||||
|
||||
return {
|
||||
display: function(d, q) {
|
||||
init();
|
||||
data = d;
|
||||
term = q;
|
||||
fillList();
|
||||
},
|
||||
next: function() {
|
||||
moveSelect(1);
|
||||
},
|
||||
prev: function() {
|
||||
moveSelect(-1);
|
||||
},
|
||||
pageUp: function() {
|
||||
if (active != 0 && active - 8 < 0) {
|
||||
moveSelect( -active );
|
||||
} else {
|
||||
moveSelect(-8);
|
||||
}
|
||||
},
|
||||
pageDown: function() {
|
||||
if (active != listItems.size() - 1 && active + 8 > listItems.size()) {
|
||||
moveSelect( listItems.size() - 1 - active );
|
||||
} else {
|
||||
moveSelect(8);
|
||||
}
|
||||
},
|
||||
hide: function() {
|
||||
element && element.hide();
|
||||
listItems && listItems.removeClass(CLASSES.ACTIVE);
|
||||
active = -1;
|
||||
},
|
||||
visible : function() {
|
||||
return element && element.is(":visible");
|
||||
},
|
||||
current: function() {
|
||||
return this.visible() && (listItems.filter("." + CLASSES.ACTIVE)[0] || options.selectFirst && listItems[0]);
|
||||
},
|
||||
show: function() {
|
||||
var offset = $(input).offset();
|
||||
element.css({
|
||||
width: typeof options.width == "string" || options.width > 0 ? options.width : $(input).width(),
|
||||
top: offset.top + input.offsetHeight,
|
||||
left: offset.left
|
||||
}).show();
|
||||
if(options.scroll) {
|
||||
list.scrollTop(0);
|
||||
list.css({
|
||||
maxHeight: options.scrollHeight,
|
||||
overflow: 'auto'
|
||||
});
|
||||
|
||||
if($.browser.msie && typeof document.body.style.maxHeight === "undefined") {
|
||||
var listHeight = 0;
|
||||
listItems.each(function() {
|
||||
listHeight += this.offsetHeight;
|
||||
});
|
||||
var scrollbarsVisible = listHeight > options.scrollHeight;
|
||||
list.css('height', scrollbarsVisible ? options.scrollHeight : listHeight );
|
||||
if (!scrollbarsVisible) {
|
||||
// IE doesn't recalculate width when scrollbar disappears
|
||||
listItems.width( list.width() - parseInt(listItems.css("padding-left")) - parseInt(listItems.css("padding-right")) );
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
},
|
||||
selected: function() {
|
||||
var selected = listItems && listItems.filter("." + CLASSES.ACTIVE).removeClass(CLASSES.ACTIVE);
|
||||
return selected && selected.length && $.data(selected[0], "ac_data");
|
||||
},
|
||||
emptyList: function (){
|
||||
list && list.empty();
|
||||
},
|
||||
unbind: function() {
|
||||
element && element.remove();
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
$.fn.selection = function(start, end) {
|
||||
if (start !== undefined) {
|
||||
return this.each(function() {
|
||||
if( this.createTextRange ){
|
||||
var selRange = this.createTextRange();
|
||||
if (end === undefined || start == end) {
|
||||
selRange.move("character", start);
|
||||
selRange.select();
|
||||
} else {
|
||||
selRange.collapse(true);
|
||||
selRange.moveStart("character", start);
|
||||
selRange.moveEnd("character", end);
|
||||
selRange.select();
|
||||
}
|
||||
} else if( this.setSelectionRange ){
|
||||
this.setSelectionRange(start, end);
|
||||
} else if( this.selectionStart ){
|
||||
this.selectionStart = start;
|
||||
this.selectionEnd = end;
|
||||
}
|
||||
});
|
||||
}
|
||||
var field = this[0];
|
||||
if ( field.createTextRange ) {
|
||||
var range = document.selection.createRange(),
|
||||
orig = field.value,
|
||||
teststring = "<->",
|
||||
textLength = range.text.length;
|
||||
range.text = teststring;
|
||||
var caretAt = field.value.indexOf(teststring);
|
||||
field.value = orig;
|
||||
this.selection(caretAt, caretAt + textLength);
|
||||
return {
|
||||
start: caretAt,
|
||||
end: caretAt + textLength
|
||||
}
|
||||
} else if( field.selectionStart !== undefined ){
|
||||
return {
|
||||
start: field.selectionStart,
|
||||
end: field.selectionEnd
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
})(jQuery);
|
1378
yii/assets/7b3570a4/jquery.ba-bbq.js
Normal file
18
yii/assets/7b3570a4/jquery.ba-bbq.min.js
vendored
Normal file
@ -0,0 +1,18 @@
|
||||
/*
|
||||
* jQuery BBQ: Back Button & Query Library - v1.3pre - 8/26/2010
|
||||
* http://benalman.com/projects/jquery-bbq-plugin/
|
||||
*
|
||||
* Copyright (c) 2010 "Cowboy" Ben Alman
|
||||
* Dual licensed under the MIT and GPL licenses.
|
||||
* http://benalman.com/about/license/
|
||||
*/
|
||||
(function($,r){var h,n=Array.prototype.slice,t=decodeURIComponent,a=$.param,j,c,m,y,b=$.bbq=$.bbq||{},s,x,k,e=$.event.special,d="hashchange",B="querystring",F="fragment",z="elemUrlAttr",l="href",w="src",p=/^.*\?|#.*$/g,u,H,g,i,C,E={};function G(I){return typeof I==="string"}function D(J){var I=n.call(arguments,1);return function(){return J.apply(this,I.concat(n.call(arguments)))}}function o(I){return I.replace(H,"$2")}function q(I){return I.replace(/(?:^[^?#]*\?([^#]*).*$)?.*/,"$1")}function f(K,P,I,L,J){var R,O,N,Q,M;if(L!==h){N=I.match(K?H:/^([^#?]*)\??([^#]*)(#?.*)/);M=N[3]||"";if(J===2&&G(L)){O=L.replace(K?u:p,"")}else{Q=m(N[2]);L=G(L)?m[K?F:B](L):L;O=J===2?L:J===1?$.extend({},L,Q):$.extend({},Q,L);O=j(O);if(K){O=O.replace(g,t)}}R=N[1]+(K?C:O||!N[1]?"?":"")+O+M}else{R=P(I!==h?I:location.href)}return R}a[B]=D(f,0,q);a[F]=c=D(f,1,o);a.sorted=j=function(J,K){var I=[],L={};$.each(a(J,K).split("&"),function(P,M){var O=M.replace(/(?:%5B|=).*$/,""),N=L[O];if(!N){N=L[O]=[];I.push(O)}N.push(M)});return $.map(I.sort(),function(M){return L[M]}).join("&")};c.noEscape=function(J){J=J||"";var I=$.map(J.split(""),encodeURIComponent);g=new RegExp(I.join("|"),"g")};c.noEscape(",/");c.ajaxCrawlable=function(I){if(I!==h){if(I){u=/^.*(?:#!|#)/;H=/^([^#]*)(?:#!|#)?(.*)$/;C="#!"}else{u=/^.*#/;H=/^([^#]*)#?(.*)$/;C="#"}i=!!I}return i};c.ajaxCrawlable(0);$.deparam=m=function(L,I){var K={},J={"true":!0,"false":!1,"null":null};$.each(L.replace(/\+/g," ").split("&"),function(O,T){var N=T.split("="),S=t(N[0]),M,R=K,P=0,U=S.split("]["),Q=U.length-1;if(/\[/.test(U[0])&&/\]$/.test(U[Q])){U[Q]=U[Q].replace(/\]$/,"");U=U.shift().split("[").concat(U);Q=U.length-1}else{Q=0}if(N.length===2){M=t(N[1]);if(I){M=M&&!isNaN(M)?+M:M==="undefined"?h:J[M]!==h?J[M]:M}if(Q){for(;P<=Q;P++){S=U[P]===""?R.length:U[P];R=R[S]=P<Q?R[S]||(U[P+1]&&isNaN(U[P+1])?{}:[]):M}}else{if($.isArray(K[S])){K[S].push(M)}else{if(K[S]!==h){K[S]=[K[S],M]}else{K[S]=M}}}}else{if(S){K[S]=I?h:""}}});return K};function A(K,I,J){if(I===h||typeof I==="boolean"){J=I;I=a[K?F:B]()}else{I=G(I)?I.replace(K?u:p,""):I}return m(I,J)}m[B]=D(A,0);m[F]=y=D(A,1);$[z]||($[z]=function(I){return $.extend(E,I)})({a:l,base:l,iframe:w,img:w,input:w,form:"action",link:l,script:w});k=$[z];function v(L,J,K,I){if(!G(K)&&typeof K!=="object"){I=K;K=J;J=h}return this.each(function(){var O=$(this),M=J||k()[(this.nodeName||"").toLowerCase()]||"",N=M&&O.attr(M)||"";O.attr(M,a[L](N,K,I))})}$.fn[B]=D(v,B);$.fn[F]=D(v,F);b.pushState=s=function(L,I){if(G(L)&&/^#/.test(L)&&I===h){I=2}var K=L!==h,J=c(location.href,K?L:{},K?I:2);location.href=J};b.getState=x=function(I,J){return I===h||typeof I==="boolean"?y(I):y(J)[I]};b.removeState=function(I){var J={};if(I!==h){J=x();$.each($.isArray(I)?I:arguments,function(L,K){delete J[K]})}s(J,2)};e[d]=$.extend(e[d],{add:function(I){var K;function J(M){var L=M[F]=c();M.getState=function(N,O){return N===h||typeof N==="boolean"?m(L,N):m(L,O)[N]};K.apply(this,arguments)}if($.isFunction(I)){K=I;return J}else{K=I.handler;I.handler=J}}})})(jQuery,this);
|
||||
/*
|
||||
* jQuery hashchange event - v1.3 - 7/21/2010
|
||||
* http://benalman.com/projects/jquery-hashchange-plugin/
|
||||
*
|
||||
* Copyright (c) 2010 "Cowboy" Ben Alman
|
||||
* Dual licensed under the MIT and GPL licenses.
|
||||
* http://benalman.com/about/license/
|
||||
*/
|
||||
(function($,e,b){var c="hashchange",h=document,f,g=$.event.special,i=h.documentMode,d="on"+c in e&&(i===b||i>7);function a(j){j=j||location.href;return"#"+j.replace(/^[^#]*#?(.*)$/,"$1")}$.fn[c]=function(j){return j?this.bind(c,j):this.trigger(c)};$.fn[c].delay=50;g[c]=$.extend(g[c],{setup:function(){if(d){return false}$(f.start)},teardown:function(){if(d){return false}$(f.stop)}});f=(function(){var j={},p,m=a(),k=function(q){return q},l=k,o=k;j.start=function(){p||n()};j.stop=function(){p&&clearTimeout(p);p=b};function n(){var r=a(),q=o(m);if(r!==m){l(m=r,q);$(e).trigger(c)}else{if(q!==m){location.href=location.href.replace(/#.*/,"")+q}}p=setTimeout(n,$.fn[c].delay)}!d&&(function(){var q,r;j.start=function(){if(!q){r=$.fn[c].src;r=r&&r+a();q=$('<iframe tabindex="-1" title="empty"/>').hide().one("load",function(){r||l(a());n()}).attr("src",r||"javascript:0").insertAfter("body")[0].contentWindow;h.onpropertychange=function(){try{if(event.propertyName==="title"){q.document.title=h.title}}catch(s){}}}};j.stop=k;o=function(){return a(q.location.href)};l=function(v,s){var u=q.document,t=$.fn[c].domain;if(v!==s){u.title=h.title;u.open();t&&u.write('<script>document.domain="'+t+'"<\/script>');u.close();q.location.hash=v}}})();return j})()})(jQuery,this);
|
39
yii/assets/7b3570a4/jquery.bgiframe.js
Normal file
@ -0,0 +1,39 @@
|
||||
/*! Copyright (c) 2010 Brandon Aaron (http://brandonaaron.net)
|
||||
* Licensed under the MIT License (LICENSE.txt).
|
||||
*
|
||||
* Version 2.1.2
|
||||
*/
|
||||
|
||||
(function($){
|
||||
|
||||
$.fn.bgiframe = ($.browser.msie && /msie 6\.0/i.test(navigator.userAgent) ? function(s) {
|
||||
s = $.extend({
|
||||
top : 'auto', // auto == .currentStyle.borderTopWidth
|
||||
left : 'auto', // auto == .currentStyle.borderLeftWidth
|
||||
width : 'auto', // auto == offsetWidth
|
||||
height : 'auto', // auto == offsetHeight
|
||||
opacity : true,
|
||||
src : 'javascript:false;'
|
||||
}, s);
|
||||
var html = '<iframe class="bgiframe"frameborder="0"tabindex="-1"src="'+s.src+'"'+
|
||||
'style="display:block;position:absolute;z-index:-1;'+
|
||||
(s.opacity !== false?'filter:Alpha(Opacity=\'0\');':'')+
|
||||
'top:'+(s.top=='auto'?'expression(((parseInt(this.parentNode.currentStyle.borderTopWidth)||0)*-1)+\'px\')':prop(s.top))+';'+
|
||||
'left:'+(s.left=='auto'?'expression(((parseInt(this.parentNode.currentStyle.borderLeftWidth)||0)*-1)+\'px\')':prop(s.left))+';'+
|
||||
'width:'+(s.width=='auto'?'expression(this.parentNode.offsetWidth+\'px\')':prop(s.width))+';'+
|
||||
'height:'+(s.height=='auto'?'expression(this.parentNode.offsetHeight+\'px\')':prop(s.height))+';'+
|
||||
'"/>';
|
||||
return this.each(function() {
|
||||
if ( $(this).children('iframe.bgiframe').length === 0 )
|
||||
this.insertBefore( document.createElement(html), this.firstChild );
|
||||
});
|
||||
} : function() { return this; });
|
||||
|
||||
// old alias
|
||||
$.fn.bgIframe = $.fn.bgiframe;
|
||||
|
||||
function prop(n) {
|
||||
return n && n.constructor === Number ? n + 'px' : n;
|
||||
}
|
||||
|
||||
})(jQuery);
|
92
yii/assets/7b3570a4/jquery.cookie.js
Normal file
@ -0,0 +1,92 @@
|
||||
/**
|
||||
* Cookie plugin
|
||||
*
|
||||
* Copyright (c) 2006 Klaus Hartl (stilbuero.de)
|
||||
* Dual licensed under the MIT and GPL licenses:
|
||||
* http://www.opensource.org/licenses/mit-license.php
|
||||
* http://www.gnu.org/licenses/gpl.html
|
||||
*
|
||||
*/
|
||||
|
||||
/**
|
||||
* Create a cookie with the given name and value and other optional parameters.
|
||||
*
|
||||
* @example $.cookie('the_cookie', 'the_value');
|
||||
* @desc Set the value of a cookie.
|
||||
* @example $.cookie('the_cookie', 'the_value', {expires: 7, path: '/', domain: 'jquery.com', secure: true});
|
||||
* @desc Create a cookie with all available options.
|
||||
* @example $.cookie('the_cookie', 'the_value');
|
||||
* @desc Create a session cookie.
|
||||
* @example $.cookie('the_cookie', null);
|
||||
* @desc Delete a cookie by passing null as value.
|
||||
*
|
||||
* @param String name The name of the cookie.
|
||||
* @param String value The value of the cookie.
|
||||
* @param Object options An object literal containing key/value pairs to provide optional cookie attributes.
|
||||
* @option Number|Date expires Either an integer specifying the expiration date from now on in days or a Date object.
|
||||
* If a negative value is specified (e.g. a date in the past), the cookie will be deleted.
|
||||
* If set to null or omitted, the cookie will be a session cookie and will not be retained
|
||||
* when the the browser exits.
|
||||
* @option String path The value of the path atribute of the cookie (default: path of page that created the cookie).
|
||||
* @option String domain The value of the domain attribute of the cookie (default: domain of page that created the cookie).
|
||||
* @option Boolean secure If true, the secure attribute of the cookie will be set and the cookie transmission will
|
||||
* require a secure protocol (like HTTPS).
|
||||
* @type undefined
|
||||
*
|
||||
* @name $.cookie
|
||||
* @cat Plugins/Cookie
|
||||
* @author Klaus Hartl/klaus.hartl@stilbuero.de
|
||||
*/
|
||||
|
||||
/**
|
||||
* Get the value of a cookie with the given name.
|
||||
*
|
||||
* @example $.cookie('the_cookie');
|
||||
* @desc Get the value of a cookie.
|
||||
*
|
||||
* @param String name The name of the cookie.
|
||||
* @return The value of the cookie.
|
||||
* @type String
|
||||
*
|
||||
* @name $.cookie
|
||||
* @cat Plugins/Cookie
|
||||
* @author Klaus Hartl/klaus.hartl@stilbuero.de
|
||||
*/
|
||||
jQuery.cookie = function(name, value, options) {
|
||||
if (typeof value != 'undefined') { // name and value given, set cookie
|
||||
options = options || {};
|
||||
if (value === null) {
|
||||
value = '';
|
||||
options.expires = -1;
|
||||
}
|
||||
var expires = '';
|
||||
if (options.expires && (typeof options.expires == 'number' || options.expires.toUTCString)) {
|
||||
var date;
|
||||
if (typeof options.expires == 'number') {
|
||||
date = new Date();
|
||||
date.setTime(date.getTime() + (options.expires * 24 * 60 * 60 * 1000));
|
||||
} else {
|
||||
date = options.expires;
|
||||
}
|
||||
expires = '; expires=' + date.toUTCString(); // use expires attribute, max-age is not supported by IE
|
||||
}
|
||||
var path = options.path ? '; path=' + options.path : '';
|
||||
var domain = options.domain ? '; domain=' + options.domain : '';
|
||||
var secure = options.secure ? '; secure' : '';
|
||||
document.cookie = [name, '=', encodeURIComponent(value), expires, path, domain, secure].join('');
|
||||
} else { // only name given, get cookie
|
||||
var cookieValue = null;
|
||||
if (document.cookie && document.cookie != '') {
|
||||
var cookies = document.cookie.split(';');
|
||||
for (var i = 0; i < cookies.length; i++) {
|
||||
var cookie = jQuery.trim(cookies[i]);
|
||||
// Does this cookie string begin with the name we want?
|
||||
if (cookie.substring(0, name.length + 1) == (name + '=')) {
|
||||
cookieValue = decodeURIComponent(cookie.substring(name.length + 1));
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
return cookieValue;
|
||||
}
|
||||
};
|
1
yii/assets/7b3570a4/jquery.history.js
Normal file
9472
yii/assets/7b3570a4/jquery.js
vendored
Normal file
338
yii/assets/7b3570a4/jquery.maskedinput.js
Normal file
@ -0,0 +1,338 @@
|
||||
/*
|
||||
Masked Input plugin for jQuery
|
||||
Copyright (c) 2007-2013 Josh Bush (digitalbush.com)
|
||||
Licensed under the MIT license (http://digitalbush.com/projects/masked-input-plugin/#license)
|
||||
Version: 1.3.1
|
||||
*/
|
||||
(function($) {
|
||||
function getPasteEvent() {
|
||||
var el = document.createElement('input'),
|
||||
name = 'onpaste';
|
||||
el.setAttribute(name, '');
|
||||
return (typeof el[name] === 'function')?'paste':'input';
|
||||
}
|
||||
|
||||
var pasteEventName = getPasteEvent() + ".mask",
|
||||
ua = navigator.userAgent,
|
||||
iPhone = /iphone/i.test(ua),
|
||||
android=/android/i.test(ua),
|
||||
caretTimeoutId;
|
||||
|
||||
$.mask = {
|
||||
//Predefined character definitions
|
||||
definitions: {
|
||||
'9': "[0-9]",
|
||||
'a': "[A-Za-z]",
|
||||
'*': "[A-Za-z0-9]"
|
||||
},
|
||||
dataName: "rawMaskFn",
|
||||
placeholder: '_',
|
||||
};
|
||||
|
||||
$.fn.extend({
|
||||
//Helper Function for Caret positioning
|
||||
caret: function(begin, end) {
|
||||
var range;
|
||||
|
||||
if (this.length === 0 || this.is(":hidden")) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (typeof begin == 'number') {
|
||||
end = (typeof end === 'number') ? end : begin;
|
||||
return this.each(function() {
|
||||
if (this.setSelectionRange) {
|
||||
this.setSelectionRange(begin, end);
|
||||
} else if (this.createTextRange) {
|
||||
range = this.createTextRange();
|
||||
range.collapse(true);
|
||||
range.moveEnd('character', end);
|
||||
range.moveStart('character', begin);
|
||||
range.select();
|
||||
}
|
||||
});
|
||||
} else {
|
||||
if (this[0].setSelectionRange) {
|
||||
begin = this[0].selectionStart;
|
||||
end = this[0].selectionEnd;
|
||||
} else if (document.selection && document.selection.createRange) {
|
||||
range = document.selection.createRange();
|
||||
begin = 0 - range.duplicate().moveStart('character', -100000);
|
||||
end = begin + range.text.length;
|
||||
}
|
||||
return { begin: begin, end: end };
|
||||
}
|
||||
},
|
||||
unmask: function() {
|
||||
return this.trigger("unmask");
|
||||
},
|
||||
mask: function(mask, settings) {
|
||||
var input,
|
||||
defs,
|
||||
tests,
|
||||
partialPosition,
|
||||
firstNonMaskPos,
|
||||
len;
|
||||
|
||||
if (!mask && this.length > 0) {
|
||||
input = $(this[0]);
|
||||
return input.data($.mask.dataName)();
|
||||
}
|
||||
settings = $.extend({
|
||||
placeholder: $.mask.placeholder, // Load default placeholder
|
||||
completed: null
|
||||
}, settings);
|
||||
|
||||
|
||||
defs = $.mask.definitions;
|
||||
tests = [];
|
||||
partialPosition = len = mask.length;
|
||||
firstNonMaskPos = null;
|
||||
|
||||
$.each(mask.split(""), function(i, c) {
|
||||
if (c == '?') {
|
||||
len--;
|
||||
partialPosition = i;
|
||||
} else if (defs[c]) {
|
||||
tests.push(new RegExp(defs[c]));
|
||||
if (firstNonMaskPos === null) {
|
||||
firstNonMaskPos = tests.length - 1;
|
||||
}
|
||||
} else {
|
||||
tests.push(null);
|
||||
}
|
||||
});
|
||||
|
||||
return this.trigger("unmask").each(function() {
|
||||
var input = $(this),
|
||||
buffer = $.map(
|
||||
mask.split(""),
|
||||
function(c, i) {
|
||||
if (c != '?') {
|
||||
return defs[c] ? settings.placeholder : c;
|
||||
}
|
||||
}),
|
||||
focusText = input.val();
|
||||
|
||||
function seekNext(pos) {
|
||||
while (++pos < len && !tests[pos]);
|
||||
return pos;
|
||||
}
|
||||
|
||||
function seekPrev(pos) {
|
||||
while (--pos >= 0 && !tests[pos]);
|
||||
return pos;
|
||||
}
|
||||
|
||||
function shiftL(begin,end) {
|
||||
var i,
|
||||
j;
|
||||
|
||||
if (begin<0) {
|
||||
return;
|
||||
}
|
||||
|
||||
for (i = begin, j = seekNext(end); i < len; i++) {
|
||||
if (tests[i]) {
|
||||
if (j < len && tests[i].test(buffer[j])) {
|
||||
buffer[i] = buffer[j];
|
||||
buffer[j] = settings.placeholder;
|
||||
} else {
|
||||
break;
|
||||
}
|
||||
|
||||
j = seekNext(j);
|
||||
}
|
||||
}
|
||||
writeBuffer();
|
||||
input.caret(Math.max(firstNonMaskPos, begin));
|
||||
}
|
||||
|
||||
function shiftR(pos) {
|
||||
var i,
|
||||
c,
|
||||
j,
|
||||
t;
|
||||
|
||||
for (i = pos, c = settings.placeholder; i < len; i++) {
|
||||
if (tests[i]) {
|
||||
j = seekNext(i);
|
||||
t = buffer[i];
|
||||
buffer[i] = c;
|
||||
if (j < len && tests[j].test(t)) {
|
||||
c = t;
|
||||
} else {
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function keydownEvent(e) {
|
||||
var k = e.which,
|
||||
pos,
|
||||
begin,
|
||||
end;
|
||||
|
||||
//backspace, delete, and escape get special treatment
|
||||
if (k === 8 || k === 46 || (iPhone && k === 127)) {
|
||||
pos = input.caret();
|
||||
begin = pos.begin;
|
||||
end = pos.end;
|
||||
|
||||
if (end - begin === 0) {
|
||||
begin=k!==46?seekPrev(begin):(end=seekNext(begin-1));
|
||||
end=k===46?seekNext(end):end;
|
||||
}
|
||||
clearBuffer(begin, end);
|
||||
shiftL(begin, end - 1);
|
||||
|
||||
e.preventDefault();
|
||||
} else if (k == 27) {//escape
|
||||
input.val(focusText);
|
||||
input.caret(0, checkVal());
|
||||
e.preventDefault();
|
||||
}
|
||||
}
|
||||
|
||||
function keypressEvent(e) {
|
||||
var k = e.which,
|
||||
pos = input.caret(),
|
||||
p,
|
||||
c,
|
||||
next;
|
||||
|
||||
if (e.ctrlKey || e.altKey || e.metaKey || k < 32) {//Ignore
|
||||
return;
|
||||
} else if (k) {
|
||||
if (pos.end - pos.begin !== 0){
|
||||
clearBuffer(pos.begin, pos.end);
|
||||
shiftL(pos.begin, pos.end-1);
|
||||
}
|
||||
|
||||
p = seekNext(pos.begin - 1);
|
||||
if (p < len) {
|
||||
c = String.fromCharCode(k);
|
||||
if (tests[p].test(c)) {
|
||||
shiftR(p);
|
||||
|
||||
buffer[p] = c;
|
||||
writeBuffer();
|
||||
next = seekNext(p);
|
||||
|
||||
if(android){
|
||||
setTimeout($.proxy($.fn.caret,input,next),0);
|
||||
}else{
|
||||
input.caret(next);
|
||||
}
|
||||
|
||||
if (settings.completed && next >= len) {
|
||||
settings.completed.call(input);
|
||||
}
|
||||
}
|
||||
}
|
||||
e.preventDefault();
|
||||
}
|
||||
}
|
||||
|
||||
function clearBuffer(start, end) {
|
||||
var i;
|
||||
for (i = start; i < end && i < len; i++) {
|
||||
if (tests[i]) {
|
||||
buffer[i] = settings.placeholder;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function writeBuffer() { input.val(buffer.join('')); }
|
||||
|
||||
function checkVal(allow) {
|
||||
//try to place characters where they belong
|
||||
var test = input.val(),
|
||||
lastMatch = -1,
|
||||
i,
|
||||
c;
|
||||
|
||||
for (i = 0, pos = 0; i < len; i++) {
|
||||
if (tests[i]) {
|
||||
buffer[i] = settings.placeholder;
|
||||
while (pos++ < test.length) {
|
||||
c = test.charAt(pos - 1);
|
||||
if (tests[i].test(c)) {
|
||||
buffer[i] = c;
|
||||
lastMatch = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (pos > test.length) {
|
||||
break;
|
||||
}
|
||||
} else if (buffer[i] === test.charAt(pos) && i !== partialPosition) {
|
||||
pos++;
|
||||
lastMatch = i;
|
||||
}
|
||||
}
|
||||
if (allow) {
|
||||
writeBuffer();
|
||||
} else if (lastMatch + 1 < partialPosition) {
|
||||
input.val("");
|
||||
clearBuffer(0, len);
|
||||
} else {
|
||||
writeBuffer();
|
||||
input.val(input.val().substring(0, lastMatch + 1));
|
||||
}
|
||||
return (partialPosition ? i : firstNonMaskPos);
|
||||
}
|
||||
|
||||
input.data($.mask.dataName,function(){
|
||||
return $.map(buffer, function(c, i) {
|
||||
return tests[i]&&c!=settings.placeholder ? c : null;
|
||||
}).join('');
|
||||
});
|
||||
|
||||
if (!input.attr("readonly"))
|
||||
input
|
||||
.one("unmask", function() {
|
||||
input
|
||||
.unbind(".mask")
|
||||
.removeData($.mask.dataName);
|
||||
})
|
||||
.bind("focus.mask", function() {
|
||||
clearTimeout(caretTimeoutId);
|
||||
var pos,
|
||||
moveCaret;
|
||||
|
||||
focusText = input.val();
|
||||
pos = checkVal();
|
||||
|
||||
caretTimeoutId = setTimeout(function(){
|
||||
writeBuffer();
|
||||
if (pos == mask.length) {
|
||||
input.caret(0, pos);
|
||||
} else {
|
||||
input.caret(pos);
|
||||
}
|
||||
}, 10);
|
||||
})
|
||||
.bind("blur.mask", function() {
|
||||
checkVal();
|
||||
if (input.val() != focusText)
|
||||
input.change();
|
||||
})
|
||||
.bind("keydown.mask", keydownEvent)
|
||||
.bind("keypress.mask", keypressEvent)
|
||||
.bind(pasteEventName, function() {
|
||||
setTimeout(function() {
|
||||
var pos=checkVal(true);
|
||||
input.caret(pos);
|
||||
if (settings.completed && pos == input.val().length)
|
||||
settings.completed.call(input);
|
||||
}, 0);
|
||||
});
|
||||
checkVal(); //Perform initial check for existing values
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
})(jQuery);
|
7
yii/assets/7b3570a4/jquery.maskedinput.min.js
vendored
Normal file
@ -0,0 +1,7 @@
|
||||
/*
|
||||
Masked Input plugin for jQuery
|
||||
Copyright (c) 2007-2013 Josh Bush (digitalbush.com)
|
||||
Licensed under the MIT license (http://digitalbush.com/projects/masked-input-plugin/#license)
|
||||
Version: 1.3.1
|
||||
*/
|
||||
(function(e){function t(){var e=document.createElement("input"),t="onpaste";return e.setAttribute(t,""),"function"==typeof e[t]?"paste":"input"}var n,a=t()+".mask",r=navigator.userAgent,i=/iphone/i.test(r),o=/android/i.test(r);e.mask={definitions:{9:"[0-9]",a:"[A-Za-z]","*":"[A-Za-z0-9]"},dataName:"rawMaskFn",placeholder:"_"},e.fn.extend({caret:function(e,t){var n;if(0!==this.length&&!this.is(":hidden"))return"number"==typeof e?(t="number"==typeof t?t:e,this.each(function(){this.setSelectionRange?this.setSelectionRange(e,t):this.createTextRange&&(n=this.createTextRange(),n.collapse(!0),n.moveEnd("character",t),n.moveStart("character",e),n.select())})):(this[0].setSelectionRange?(e=this[0].selectionStart,t=this[0].selectionEnd):document.selection&&document.selection.createRange&&(n=document.selection.createRange(),e=0-n.duplicate().moveStart("character",-1e5),t=e+n.text.length),{begin:e,end:t})},unmask:function(){return this.trigger("unmask")},mask:function(t,r){var c,l,s,u,f,h;return!t&&this.length>0?(c=e(this[0]),c.data(e.mask.dataName)()):(r=e.extend({placeholder:e.mask.placeholder,completed:null},r),l=e.mask.definitions,s=[],u=h=t.length,f=null,e.each(t.split(""),function(e,t){"?"==t?(h--,u=e):l[t]?(s.push(RegExp(l[t])),null===f&&(f=s.length-1)):s.push(null)}),this.trigger("unmask").each(function(){function c(e){for(;h>++e&&!s[e];);return e}function d(e){for(;--e>=0&&!s[e];);return e}function m(e,t){var n,a;if(!(0>e)){for(n=e,a=c(t);h>n;n++)if(s[n]){if(!(h>a&&s[n].test(R[a])))break;R[n]=R[a],R[a]=r.placeholder,a=c(a)}b(),x.caret(Math.max(f,e))}}function p(e){var t,n,a,i;for(t=e,n=r.placeholder;h>t;t++)if(s[t]){if(a=c(t),i=R[t],R[t]=n,!(h>a&&s[a].test(i)))break;n=i}}function g(e){var t,n,a,r=e.which;8===r||46===r||i&&127===r?(t=x.caret(),n=t.begin,a=t.end,0===a-n&&(n=46!==r?d(n):a=c(n-1),a=46===r?c(a):a),k(n,a),m(n,a-1),e.preventDefault()):27==r&&(x.val(S),x.caret(0,y()),e.preventDefault())}function v(t){var n,a,i,l=t.which,u=x.caret();t.ctrlKey||t.altKey||t.metaKey||32>l||l&&(0!==u.end-u.begin&&(k(u.begin,u.end),m(u.begin,u.end-1)),n=c(u.begin-1),h>n&&(a=String.fromCharCode(l),s[n].test(a)&&(p(n),R[n]=a,b(),i=c(n),o?setTimeout(e.proxy(e.fn.caret,x,i),0):x.caret(i),r.completed&&i>=h&&r.completed.call(x))),t.preventDefault())}function k(e,t){var n;for(n=e;t>n&&h>n;n++)s[n]&&(R[n]=r.placeholder)}function b(){x.val(R.join(""))}function y(e){var t,n,a=x.val(),i=-1;for(t=0,pos=0;h>t;t++)if(s[t]){for(R[t]=r.placeholder;pos++<a.length;)if(n=a.charAt(pos-1),s[t].test(n)){R[t]=n,i=t;break}if(pos>a.length)break}else R[t]===a.charAt(pos)&&t!==u&&(pos++,i=t);return e?b():u>i+1?(x.val(""),k(0,h)):(b(),x.val(x.val().substring(0,i+1))),u?t:f}var x=e(this),R=e.map(t.split(""),function(e){return"?"!=e?l[e]?r.placeholder:e:void 0}),S=x.val();x.data(e.mask.dataName,function(){return e.map(R,function(e,t){return s[t]&&e!=r.placeholder?e:null}).join("")}),x.attr("readonly")||x.one("unmask",function(){x.unbind(".mask").removeData(e.mask.dataName)}).bind("focus.mask",function(){clearTimeout(n);var e;S=x.val(),e=y(),n=setTimeout(function(){b(),e==t.length?x.caret(0,e):x.caret(e)},10)}).bind("blur.mask",function(){y(),x.val()!=S&&x.change()}).bind("keydown.mask",g).bind("keypress.mask",v).bind(a,function(){setTimeout(function(){var e=y(!0);x.caret(e),r.completed&&e==x.val().length&&r.completed.call(x)},0)}),y()}))}})})(jQuery);
|
148
yii/assets/7b3570a4/jquery.metadata.js
Normal file
@ -0,0 +1,148 @@
|
||||
/*
|
||||
* Metadata - jQuery plugin for parsing metadata from elements
|
||||
*
|
||||
* Copyright (c) 2006 John Resig, Yehuda Katz, J<EFBFBD>örn Zaefferer, Paul McLanahan
|
||||
*
|
||||
* Dual licensed under the MIT and GPL licenses:
|
||||
* http://www.opensource.org/licenses/mit-license.php
|
||||
* http://www.gnu.org/licenses/gpl.html
|
||||
*
|
||||
* Revision: $Id: jquery.metadata.js 3640 2007-10-11 18:34:38Z pmclanahan $
|
||||
*
|
||||
*/
|
||||
|
||||
/**
|
||||
* Sets the type of metadata to use. Metadata is encoded in JSON, and each property
|
||||
* in the JSON will become a property of the element itself.
|
||||
*
|
||||
* There are four supported types of metadata storage:
|
||||
*
|
||||
* attr: Inside an attribute. The name parameter indicates *which* attribute.
|
||||
*
|
||||
* class: Inside the class attribute, wrapped in curly braces: { }
|
||||
*
|
||||
* elem: Inside a child element (e.g. a script tag). The
|
||||
* name parameter indicates *which* element.
|
||||
* html5: Values are stored in data-* attributes.
|
||||
*
|
||||
* The metadata for an element is loaded the first time the element is accessed via jQuery.
|
||||
*
|
||||
* As a result, you can define the metadata type, use $(expr) to load the metadata into the elements
|
||||
* matched by expr, then redefine the metadata type and run another $(expr) for other elements.
|
||||
*
|
||||
* @name $.metadata.setType
|
||||
*
|
||||
* @example <p id="one" class="some_class {item_id: 1, item_label: 'Label'}">This is a p</p>
|
||||
* @before $.metadata.setType("class")
|
||||
* @after $("#one").metadata().item_id == 1; $("#one").metadata().item_label == "Label"
|
||||
* @desc Reads metadata from the class attribute
|
||||
*
|
||||
* @example <p id="one" class="some_class" data="{item_id: 1, item_label: 'Label'}">This is a p</p>
|
||||
* @before $.metadata.setType("attr", "data")
|
||||
* @after $("#one").metadata().item_id == 1; $("#one").metadata().item_label == "Label"
|
||||
* @desc Reads metadata from a "data" attribute
|
||||
*
|
||||
* @example <p id="one" class="some_class"><script>{item_id: 1, item_label: 'Label'}</script>This is a p</p>
|
||||
* @before $.metadata.setType("elem", "script")
|
||||
* @after $("#one").metadata().item_id == 1; $("#one").metadata().item_label == "Label"
|
||||
* @desc Reads metadata from a nested script element
|
||||
*
|
||||
* @example <p id="one" class="some_class" data-item_id="1" data-item_label="Label">This is a p</p>
|
||||
* @before $.metadata.setType("html5")
|
||||
* @after $("#one").metadata().item_id == 1; $("#one").metadata().item_label == "Label"
|
||||
* @desc Reads metadata from a series of data-* attributes
|
||||
*
|
||||
* @param String type The encoding type
|
||||
* @param String name The name of the attribute to be used to get metadata (optional)
|
||||
* @cat Plugins/Metadata
|
||||
* @descr Sets the type of encoding to be used when loading metadata for the first time
|
||||
* @type undefined
|
||||
* @see metadata()
|
||||
*/
|
||||
|
||||
(function($) {
|
||||
|
||||
$.extend({
|
||||
metadata : {
|
||||
defaults : {
|
||||
type: 'class',
|
||||
name: 'metadata',
|
||||
cre: /({.*})/,
|
||||
single: 'metadata'
|
||||
},
|
||||
setType: function( type, name ){
|
||||
this.defaults.type = type;
|
||||
this.defaults.name = name;
|
||||
},
|
||||
get: function( elem, opts ){
|
||||
var settings = $.extend({},this.defaults,opts);
|
||||
// check for empty string in single property
|
||||
if ( !settings.single.length ) settings.single = 'metadata';
|
||||
|
||||
var data = $.data(elem, settings.single);
|
||||
// returned cached data if it already exists
|
||||
if ( data ) return data;
|
||||
|
||||
data = "{}";
|
||||
|
||||
var getData = function(data) {
|
||||
if(typeof data != "string") return data;
|
||||
|
||||
if( data.indexOf('{') < 0 ) {
|
||||
data = eval("(" + data + ")");
|
||||
}
|
||||
};
|
||||
|
||||
var getObject = function(data) {
|
||||
if(typeof data != "string") return data;
|
||||
|
||||
data = eval("(" + data + ")");
|
||||
return data;
|
||||
};
|
||||
|
||||
if ( settings.type == "html5" ) {
|
||||
var object = {};
|
||||
$( elem.attributes ).each(function() {
|
||||
var name = this.nodeName;
|
||||
if(name.match(/^data-/)) name = name.replace(/^data-/, '');
|
||||
else return true;
|
||||
object[name] = getObject(this.nodeValue);
|
||||
});
|
||||
} else {
|
||||
if ( settings.type == "class" ) {
|
||||
var m = settings.cre.exec( elem.className );
|
||||
if ( m )
|
||||
data = m[1];
|
||||
} else if ( settings.type == "elem" ) {
|
||||
if( !elem.getElementsByTagName ) return;
|
||||
var e = elem.getElementsByTagName(settings.name);
|
||||
if ( e.length )
|
||||
data = $.trim(e[0].innerHTML);
|
||||
} else if ( elem.getAttribute != undefined ) {
|
||||
var attr = elem.getAttribute( settings.name );
|
||||
if ( attr )
|
||||
data = attr;
|
||||
}
|
||||
object = getObject(data.indexOf("{") < 0 ? "{" + data + "}" : data);
|
||||
}
|
||||
|
||||
$.data( elem, settings.single, object );
|
||||
return object;
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
/**
|
||||
* Returns the metadata object for the first member of the jQuery object.
|
||||
*
|
||||
* @name metadata
|
||||
* @descr Returns element's metadata object
|
||||
* @param Object opts An object contianing settings to override the defaults
|
||||
* @type jQuery
|
||||
* @cat Plugins/Metadata
|
||||
*/
|
||||
$.fn.metadata = function( opts ){
|
||||
return $.metadata.get( this[0], opts );
|
||||
};
|
||||
|
||||
})(jQuery);
|
2
yii/assets/7b3570a4/jquery.min.js
vendored
Normal file
536
yii/assets/7b3570a4/jquery.multifile.js
Normal file
@ -0,0 +1,536 @@
|
||||
/*
|
||||
### jQuery Multiple File Upload Plugin v1.47 - 2010-03-26 ###
|
||||
* Home: http://www.fyneworks.com/jquery/multiple-file-upload/
|
||||
* Code: http://code.google.com/p/jquery-multifile-plugin/
|
||||
*
|
||||
* Dual licensed under the MIT and GPL licenses:
|
||||
* http://www.opensource.org/licenses/mit-license.php
|
||||
* http://www.gnu.org/licenses/gpl.html
|
||||
###
|
||||
*/
|
||||
|
||||
/*# AVOID COLLISIONS #*/
|
||||
;if(window.jQuery) (function($){
|
||||
/*# AVOID COLLISIONS #*/
|
||||
|
||||
// plugin initialization
|
||||
$.fn.MultiFile = function(options){
|
||||
if(this.length==0) return this; // quick fail
|
||||
|
||||
// Handle API methods
|
||||
if(typeof arguments[0]=='string'){
|
||||
// Perform API methods on individual elements
|
||||
if(this.length>1){
|
||||
var args = arguments;
|
||||
return this.each(function(){
|
||||
$.fn.MultiFile.apply($(this), args);
|
||||
});
|
||||
};
|
||||
// Invoke API method handler
|
||||
$.fn.MultiFile[arguments[0]].apply(this, $.makeArray(arguments).slice(1) || []);
|
||||
// Quick exit...
|
||||
return this;
|
||||
};
|
||||
|
||||
// Initialize options for this call
|
||||
var options = $.extend(
|
||||
{}/* new object */,
|
||||
$.fn.MultiFile.options/* default options */,
|
||||
options || {} /* just-in-time options */
|
||||
);
|
||||
|
||||
// Empty Element Fix!!!
|
||||
// this code will automatically intercept native form submissions
|
||||
// and disable empty file elements
|
||||
$('form')
|
||||
.not('MultiFile-intercepted')
|
||||
.addClass('MultiFile-intercepted')
|
||||
.submit($.fn.MultiFile.disableEmpty);
|
||||
|
||||
//### http://plugins.jquery.com/node/1363
|
||||
// utility method to integrate this plugin with others...
|
||||
if($.fn.MultiFile.options.autoIntercept){
|
||||
$.fn.MultiFile.intercept( $.fn.MultiFile.options.autoIntercept /* array of methods to intercept */ );
|
||||
$.fn.MultiFile.options.autoIntercept = null; /* only run this once */
|
||||
};
|
||||
|
||||
// loop through each matched element
|
||||
this
|
||||
.not('.MultiFile-applied')
|
||||
.addClass('MultiFile-applied')
|
||||
.each(function(){
|
||||
//#####################################################################
|
||||
// MAIN PLUGIN FUNCTIONALITY - START
|
||||
//#####################################################################
|
||||
|
||||
// BUG 1251 FIX: http://plugins.jquery.com/project/comments/add/1251
|
||||
// variable group_count would repeat itself on multiple calls to the plugin.
|
||||
// this would cause a conflict with multiple elements
|
||||
// changes scope of variable to global so id will be unique over n calls
|
||||
window.MultiFile = (window.MultiFile || 0) + 1;
|
||||
var group_count = window.MultiFile;
|
||||
|
||||
// Copy parent attributes - Thanks to Jonas Wagner
|
||||
// we will use this one to create new input elements
|
||||
var MultiFile = {e:this, E:$(this), clone:$(this).clone()};
|
||||
|
||||
//===
|
||||
|
||||
//# USE CONFIGURATION
|
||||
if(typeof options=='number') options = {max:options};
|
||||
var o = $.extend({},
|
||||
$.fn.MultiFile.options,
|
||||
options || {},
|
||||
($.metadata? MultiFile.E.metadata(): ($.meta?MultiFile.E.data():null)) || {}, /* metadata options */
|
||||
{} /* internals */
|
||||
);
|
||||
// limit number of files that can be selected?
|
||||
if(!(o.max>0) /*IsNull(MultiFile.max)*/){
|
||||
o.max = MultiFile.E.attr('maxlength');
|
||||
if(!(o.max>0) /*IsNull(MultiFile.max)*/){
|
||||
o.max = (String(MultiFile.e.className.match(/\b(max|limit)\-([0-9]+)\b/gi) || ['']).match(/[0-9]+/gi) || [''])[0];
|
||||
if(!(o.max>0)) o.max = -1;
|
||||
else o.max = String(o.max).match(/[0-9]+/gi)[0];
|
||||
}
|
||||
};
|
||||
o.max = new Number(o.max);
|
||||
// limit extensions?
|
||||
o.accept = o.accept || MultiFile.E.attr('accept') || '';
|
||||
if(!o.accept){
|
||||
o.accept = (MultiFile.e.className.match(/\b(accept\-[\w\|]+)\b/gi)) || '';
|
||||
o.accept = new String(o.accept).replace(/^(accept|ext)\-/i,'');
|
||||
};
|
||||
|
||||
//===
|
||||
|
||||
// APPLY CONFIGURATION
|
||||
$.extend(MultiFile, o || {});
|
||||
MultiFile.STRING = $.extend({},$.fn.MultiFile.options.STRING,MultiFile.STRING);
|
||||
|
||||
//===
|
||||
|
||||
//#########################################
|
||||
// PRIVATE PROPERTIES/METHODS
|
||||
$.extend(MultiFile, {
|
||||
n: 0, // How many elements are currently selected?
|
||||
slaves: [], files: [],
|
||||
instanceKey: MultiFile.e.id || 'MultiFile'+String(group_count), // Instance Key?
|
||||
generateID: function(z){ return MultiFile.instanceKey + (z>0 ?'_F'+String(z):''); },
|
||||
trigger: function(event, element){
|
||||
var handler = MultiFile[event], value = $(element).attr('value');
|
||||
if(handler){
|
||||
var returnValue = handler(element, value, MultiFile);
|
||||
if( returnValue!=null ) return returnValue;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
});
|
||||
|
||||
//===
|
||||
|
||||
// Setup dynamic regular expression for extension validation
|
||||
// - thanks to John-Paul Bader: http://smyck.de/2006/08/11/javascript-dynamic-regular-expresions/
|
||||
if(String(MultiFile.accept).length>1){
|
||||
MultiFile.accept = MultiFile.accept.replace(/\W+/g,'|').replace(/^\W|\W$/g,'');
|
||||
MultiFile.rxAccept = new RegExp('\\.('+(MultiFile.accept?MultiFile.accept:'')+')$','gi');
|
||||
};
|
||||
|
||||
//===
|
||||
|
||||
// Create wrapper to hold our file list
|
||||
MultiFile.wrapID = MultiFile.instanceKey+'_wrap'; // Wrapper ID?
|
||||
MultiFile.E.wrap('<div class="MultiFile-wrap" id="'+MultiFile.wrapID+'"></div>');
|
||||
MultiFile.wrapper = $('#'+MultiFile.wrapID+'');
|
||||
|
||||
//===
|
||||
|
||||
// MultiFile MUST have a name - default: file1[], file2[], file3[]
|
||||
MultiFile.e.name = MultiFile.e.name || 'file'+ group_count +'[]';
|
||||
|
||||
//===
|
||||
|
||||
if(!MultiFile.list){
|
||||
// Create a wrapper for the list
|
||||
// * OPERA BUG: NO_MODIFICATION_ALLOWED_ERR ('list' is a read-only property)
|
||||
// this change allows us to keep the files in the order they were selected
|
||||
MultiFile.wrapper.append( '<div class="MultiFile-list" id="'+MultiFile.wrapID+'_list"></div>' );
|
||||
MultiFile.list = $('#'+MultiFile.wrapID+'_list');
|
||||
};
|
||||
MultiFile.list = $(MultiFile.list);
|
||||
|
||||
//===
|
||||
|
||||
// Bind a new element
|
||||
MultiFile.addSlave = function( slave, slave_count ){
|
||||
//if(window.console) console.log('MultiFile.addSlave',slave_count);
|
||||
|
||||
// Keep track of how many elements have been displayed
|
||||
MultiFile.n++;
|
||||
// Add reference to master element
|
||||
slave.MultiFile = MultiFile;
|
||||
|
||||
// BUG FIX: http://plugins.jquery.com/node/1495
|
||||
// Clear identifying properties from clones
|
||||
if(slave_count>0) slave.id = slave.name = '';
|
||||
|
||||
// Define element's ID and name (upload components need this!)
|
||||
//slave.id = slave.id || MultiFile.generateID(slave_count);
|
||||
if(slave_count>0) slave.id = MultiFile.generateID(slave_count);
|
||||
//FIX for: http://code.google.com/p/jquery-multifile-plugin/issues/detail?id=23
|
||||
|
||||
// 2008-Apr-29: New customizable naming convention (see url below)
|
||||
// http://groups.google.com/group/jquery-dev/browse_frm/thread/765c73e41b34f924#
|
||||
slave.name = String(MultiFile.namePattern
|
||||
/*master name*/.replace(/\$name/gi,$(MultiFile.clone).attr('name'))
|
||||
/*master id */.replace(/\$id/gi, $(MultiFile.clone).attr('id'))
|
||||
/*group count*/.replace(/\$g/gi, group_count)//(group_count>0?group_count:''))
|
||||
/*slave count*/.replace(/\$i/gi, slave_count)//(slave_count>0?slave_count:''))
|
||||
);
|
||||
|
||||
// If we've reached maximum number, disable input slave
|
||||
if( (MultiFile.max > 0) && ((MultiFile.n-1) > (MultiFile.max)) )//{ // MultiFile.n Starts at 1, so subtract 1 to find true count
|
||||
slave.disabled = true;
|
||||
//};
|
||||
|
||||
// Remember most recent slave
|
||||
MultiFile.current = MultiFile.slaves[slave_count] = slave;
|
||||
|
||||
// We'll use jQuery from now on
|
||||
slave = $(slave);
|
||||
|
||||
// Clear value
|
||||
slave.val('').attr('value','')[0].value = '';
|
||||
|
||||
// Stop plugin initializing on slaves
|
||||
slave.addClass('MultiFile-applied');
|
||||
|
||||
// Triggered when a file is selected
|
||||
slave.change(function(){
|
||||
//if(window.console) console.log('MultiFile.slave.change',slave_count);
|
||||
|
||||
// Lose focus to stop IE7 firing onchange again
|
||||
$(this).blur();
|
||||
|
||||
//# Trigger Event! onFileSelect
|
||||
if(!MultiFile.trigger('onFileSelect', this, MultiFile)) return false;
|
||||
//# End Event!
|
||||
|
||||
//# Retrive value of selected file from element
|
||||
var ERROR = '', v = String(this.value || ''/*.attr('value)*/);
|
||||
|
||||
// check extension
|
||||
if(MultiFile.accept && v && !v.match(MultiFile.rxAccept))//{
|
||||
ERROR = MultiFile.STRING.denied.replace('$ext', String(v.match(/\.\w{1,4}$/gi)));
|
||||
//}
|
||||
//};
|
||||
|
||||
// Disallow duplicates
|
||||
for(var f in MultiFile.slaves)//{
|
||||
if(MultiFile.slaves[f] && MultiFile.slaves[f]!=this)//{
|
||||
//console.log(MultiFile.slaves[f],MultiFile.slaves[f].value);
|
||||
if(MultiFile.slaves[f].value==v)//{
|
||||
ERROR = MultiFile.STRING.duplicate.replace('$file', v.match(/[^\/\\]+$/gi));
|
||||
//};
|
||||
//};
|
||||
//};
|
||||
|
||||
// Create a new file input element
|
||||
var newEle = $(MultiFile.clone).clone();// Copy parent attributes - Thanks to Jonas Wagner
|
||||
//# Let's remember which input we've generated so
|
||||
// we can disable the empty ones before submission
|
||||
// See: http://plugins.jquery.com/node/1495
|
||||
newEle.addClass('MultiFile');
|
||||
|
||||
// Handle error
|
||||
if(ERROR!=''){
|
||||
// Handle error
|
||||
MultiFile.error(ERROR);
|
||||
|
||||
// 2007-06-24: BUG FIX - Thanks to Adrian Wróbel <adrian [dot] wrobel [at] gmail.com>
|
||||
// Ditch the trouble maker and add a fresh new element
|
||||
MultiFile.n--;
|
||||
MultiFile.addSlave(newEle[0], slave_count);
|
||||
slave.parent().prepend(newEle);
|
||||
slave.remove();
|
||||
return false;
|
||||
};
|
||||
|
||||
// Hide this element (NB: display:none is evil!)
|
||||
$(this).css({ position:'absolute', top: '-3000px' });
|
||||
|
||||
// Add new element to the form
|
||||
slave.after(newEle);
|
||||
|
||||
// Update list
|
||||
MultiFile.addToList( this, slave_count );
|
||||
|
||||
// Bind functionality
|
||||
MultiFile.addSlave( newEle[0], slave_count+1 );
|
||||
|
||||
//# Trigger Event! afterFileSelect
|
||||
if(!MultiFile.trigger('afterFileSelect', this, MultiFile)) return false;
|
||||
//# End Event!
|
||||
|
||||
}); // slave.change()
|
||||
|
||||
// Save control to element
|
||||
$(slave).data('MultiFile', MultiFile);
|
||||
|
||||
};// MultiFile.addSlave
|
||||
// Bind a new element
|
||||
|
||||
|
||||
|
||||
// Add a new file to the list
|
||||
MultiFile.addToList = function( slave, slave_count ){
|
||||
//if(window.console) console.log('MultiFile.addToList',slave_count);
|
||||
|
||||
//# Trigger Event! onFileAppend
|
||||
if(!MultiFile.trigger('onFileAppend', slave, MultiFile)) return false;
|
||||
//# End Event!
|
||||
|
||||
// Create label elements
|
||||
var
|
||||
r = $('<div class="MultiFile-label"></div>'),
|
||||
v = String(slave.value || ''/*.attr('value)*/),
|
||||
a = $('<span class="MultiFile-title" title="'+MultiFile.STRING.selected.replace('$file', v)+'">'+MultiFile.STRING.file.replace('$file', v.match(/[^\/\\]+$/gi)[0])+'</span>'),
|
||||
b = $('<a class="MultiFile-remove" href="#'+MultiFile.wrapID+'">'+MultiFile.STRING.remove+'</a>');
|
||||
|
||||
// Insert label
|
||||
MultiFile.list.append(
|
||||
r.append(b, ' ', a)
|
||||
);
|
||||
|
||||
b
|
||||
.click(function(){
|
||||
|
||||
//# Trigger Event! onFileRemove
|
||||
if(!MultiFile.trigger('onFileRemove', slave, MultiFile)) return false;
|
||||
//# End Event!
|
||||
|
||||
MultiFile.n--;
|
||||
MultiFile.current.disabled = false;
|
||||
|
||||
// Remove element, remove label, point to current
|
||||
MultiFile.slaves[slave_count] = null;
|
||||
$(slave).remove();
|
||||
$(this).parent().remove();
|
||||
|
||||
// Show most current element again (move into view) and clear selection
|
||||
$(MultiFile.current).css({ position:'', top: '' });
|
||||
$(MultiFile.current).reset().val('').attr('value', '')[0].value = '';
|
||||
|
||||
//# Trigger Event! afterFileRemove
|
||||
if(!MultiFile.trigger('afterFileRemove', slave, MultiFile)) return false;
|
||||
//# End Event!
|
||||
|
||||
return false;
|
||||
});
|
||||
|
||||
//# Trigger Event! afterFileAppend
|
||||
if(!MultiFile.trigger('afterFileAppend', slave, MultiFile)) return false;
|
||||
//# End Event!
|
||||
|
||||
}; // MultiFile.addToList
|
||||
// Add element to selected files list
|
||||
|
||||
|
||||
|
||||
// Bind functionality to the first element
|
||||
if(!MultiFile.MultiFile) MultiFile.addSlave(MultiFile.e, 0);
|
||||
|
||||
// Increment control count
|
||||
//MultiFile.I++; // using window.MultiFile
|
||||
MultiFile.n++;
|
||||
|
||||
// Save control to element
|
||||
MultiFile.E.data('MultiFile', MultiFile);
|
||||
|
||||
|
||||
//#####################################################################
|
||||
// MAIN PLUGIN FUNCTIONALITY - END
|
||||
//#####################################################################
|
||||
}); // each element
|
||||
};
|
||||
|
||||
/*--------------------------------------------------------*/
|
||||
|
||||
/*
|
||||
### Core functionality and API ###
|
||||
*/
|
||||
$.extend($.fn.MultiFile, {
|
||||
/**
|
||||
* This method removes all selected files
|
||||
*
|
||||
* Returns a jQuery collection of all affected elements.
|
||||
*
|
||||
* @name reset
|
||||
* @type jQuery
|
||||
* @cat Plugins/MultiFile
|
||||
* @author Diego A. (http://www.fyneworks.com/)
|
||||
*
|
||||
* @example $.fn.MultiFile.reset();
|
||||
*/
|
||||
reset: function(){
|
||||
var settings = $(this).data('MultiFile');
|
||||
//if(settings) settings.wrapper.find('a.MultiFile-remove').click();
|
||||
if(settings) settings.list.find('a.MultiFile-remove').click();
|
||||
return $(this);
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* This utility makes it easy to disable all 'empty' file elements in the document before submitting a form.
|
||||
* It marks the affected elements so they can be easily re-enabled after the form submission or validation.
|
||||
*
|
||||
* Returns a jQuery collection of all affected elements.
|
||||
*
|
||||
* @name disableEmpty
|
||||
* @type jQuery
|
||||
* @cat Plugins/MultiFile
|
||||
* @author Diego A. (http://www.fyneworks.com/)
|
||||
*
|
||||
* @example $.fn.MultiFile.disableEmpty();
|
||||
* @param String class (optional) A string specifying a class to be applied to all affected elements - Default: 'mfD'.
|
||||
*/
|
||||
disableEmpty: function(klass){ klass = (typeof(klass)=='string'?klass:'')||'mfD';
|
||||
var o = [];
|
||||
$('input:file.MultiFile').each(function(){ if($(this).val()=='') o[o.length] = this; });
|
||||
return $(o).each(function(){ this.disabled = true }).addClass(klass);
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* This method re-enables 'empty' file elements that were disabled (and marked) with the $.fn.MultiFile.disableEmpty method.
|
||||
*
|
||||
* Returns a jQuery collection of all affected elements.
|
||||
*
|
||||
* @name reEnableEmpty
|
||||
* @type jQuery
|
||||
* @cat Plugins/MultiFile
|
||||
* @author Diego A. (http://www.fyneworks.com/)
|
||||
*
|
||||
* @example $.fn.MultiFile.reEnableEmpty();
|
||||
* @param String klass (optional) A string specifying the class that was used to mark affected elements - Default: 'mfD'.
|
||||
*/
|
||||
reEnableEmpty: function(klass){ klass = (typeof(klass)=='string'?klass:'')||'mfD';
|
||||
return $('input:file.'+klass).removeClass(klass).each(function(){ this.disabled = false });
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* This method will intercept other jQuery plugins and disable empty file input elements prior to form submission
|
||||
*
|
||||
|
||||
* @name intercept
|
||||
* @cat Plugins/MultiFile
|
||||
* @author Diego A. (http://www.fyneworks.com/)
|
||||
*
|
||||
* @example $.fn.MultiFile.intercept();
|
||||
* @param Array methods (optional) Array of method names to be intercepted
|
||||
*/
|
||||
intercepted: {},
|
||||
intercept: function(methods, context, args){
|
||||
var method, value; args = args || [];
|
||||
if(args.constructor.toString().indexOf("Array")<0) args = [ args ];
|
||||
if(typeof(methods)=='function'){
|
||||
$.fn.MultiFile.disableEmpty();
|
||||
value = methods.apply(context || window, args);
|
||||
//SEE-http://code.google.com/p/jquery-multifile-plugin/issues/detail?id=27
|
||||
setTimeout(function(){ $.fn.MultiFile.reEnableEmpty() },1000);
|
||||
return value;
|
||||
};
|
||||
if(methods.constructor.toString().indexOf("Array")<0) methods = [methods];
|
||||
for(var i=0;i<methods.length;i++){
|
||||
method = methods[i]+''; // make sure that we have a STRING
|
||||
if(method) (function(method){ // make sure that method is ISOLATED for the interception
|
||||
$.fn.MultiFile.intercepted[method] = $.fn[method] || function(){};
|
||||
$.fn[method] = function(){
|
||||
$.fn.MultiFile.disableEmpty();
|
||||
value = $.fn.MultiFile.intercepted[method].apply(this, arguments);
|
||||
//SEE-http://code.google.com/p/jquery-multifile-plugin/issues/detail?id=27
|
||||
setTimeout(function(){ $.fn.MultiFile.reEnableEmpty() },1000);
|
||||
return value;
|
||||
}; // interception
|
||||
})(method); // MAKE SURE THAT method IS ISOLATED for the interception
|
||||
};// for each method
|
||||
} // $.fn.MultiFile.intercept
|
||||
|
||||
});
|
||||
|
||||
/*--------------------------------------------------------*/
|
||||
|
||||
/*
|
||||
### Default Settings ###
|
||||
eg.: You can override default control like this:
|
||||
$.fn.MultiFile.options.accept = 'gif|jpg';
|
||||
*/
|
||||
$.fn.MultiFile.options = { //$.extend($.fn.MultiFile, { options: {
|
||||
accept: '', // accepted file extensions
|
||||
max: -1, // maximum number of selectable files
|
||||
|
||||
// name to use for newly created elements
|
||||
namePattern: '$name', // same name by default (which creates an array)
|
||||
|
||||
// STRING: collection lets you show messages in different languages
|
||||
STRING: {
|
||||
remove:'x',
|
||||
denied:'You cannot select a $ext file.\nTry again...',
|
||||
file:'$file',
|
||||
selected:'File selected: $file',
|
||||
duplicate:'This file has already been selected:\n$file'
|
||||
},
|
||||
|
||||
// name of methods that should be automcatically intercepted so the plugin can disable
|
||||
// extra file elements that are empty before execution and automatically re-enable them afterwards
|
||||
autoIntercept: [ 'submit', 'ajaxSubmit', 'ajaxForm', 'validate', 'valid' /* array of methods to intercept */ ],
|
||||
|
||||
// error handling function
|
||||
error: function(s){
|
||||
/*
|
||||
ERROR! blockUI is not currently working in IE
|
||||
if($.blockUI){
|
||||
$.blockUI({
|
||||
message: s.replace(/\n/gi,'<br/>'),
|
||||
css: {
|
||||
border:'none', padding:'15px', size:'12.0pt',
|
||||
backgroundColor:'#900', color:'#fff',
|
||||
opacity:'.8','-webkit-border-radius': '10px','-moz-border-radius': '10px'
|
||||
}
|
||||
});
|
||||
window.setTimeout($.unblockUI, 2000);
|
||||
}
|
||||
else//{// save a byte!
|
||||
*/
|
||||
alert(s);
|
||||
//}// save a byte!
|
||||
}
|
||||
}; //} });
|
||||
|
||||
/*--------------------------------------------------------*/
|
||||
|
||||
/*
|
||||
### Additional Methods ###
|
||||
Required functionality outside the plugin's scope
|
||||
*/
|
||||
|
||||
// Native input reset method - because this alone doesn't always work: $(element).val('').attr('value', '')[0].value = '';
|
||||
$.fn.reset = function(){ return this.each(function(){ try{ this.reset(); }catch(e){} }); };
|
||||
|
||||
/*--------------------------------------------------------*/
|
||||
|
||||
/*
|
||||
### Default implementation ###
|
||||
The plugin will attach itself to file inputs
|
||||
with the class 'multi' when the page loads
|
||||
*/
|
||||
$(function(){
|
||||
//$("input:file.multi").MultiFile();
|
||||
$("input[type=file].multi").MultiFile();
|
||||
});
|
||||
|
||||
|
||||
|
||||
/*# AVOID COLLISIONS #*/
|
||||
})(jQuery);
|
||||
/*# AVOID COLLISIONS #*/
|
376
yii/assets/7b3570a4/jquery.rating.js
Normal file
@ -0,0 +1,376 @@
|
||||
/*
|
||||
### jQuery Star Rating Plugin v4.11 - 2013-03-14 ###
|
||||
* Home: http://www.fyneworks.com/jquery/star-rating/
|
||||
* Code: http://code.google.com/p/jquery-star-rating-plugin/
|
||||
*
|
||||
* Licensed under http://en.wikipedia.org/wiki/MIT_License
|
||||
###
|
||||
*/
|
||||
|
||||
/*# AVOID COLLISIONS #*/
|
||||
;if(window.jQuery) (function($){
|
||||
/*# AVOID COLLISIONS #*/
|
||||
|
||||
// IE6 Background Image Fix
|
||||
if ((!$.support.opacity && !$.support.style)) try { document.execCommand("BackgroundImageCache", false, true)} catch(e) { };
|
||||
// Thanks to http://www.visualjquery.com/rating/rating_redux.html
|
||||
|
||||
// plugin initialization
|
||||
$.fn.rating = function(options){
|
||||
if(this.length==0) return this; // quick fail
|
||||
|
||||
// Handle API methods
|
||||
if(typeof arguments[0]=='string'){
|
||||
// Perform API methods on individual elements
|
||||
if(this.length>1){
|
||||
var args = arguments;
|
||||
return this.each(function(){
|
||||
$.fn.rating.apply($(this), args);
|
||||
});
|
||||
};
|
||||
// Invoke API method handler
|
||||
$.fn.rating[arguments[0]].apply(this, $.makeArray(arguments).slice(1) || []);
|
||||
// Quick exit...
|
||||
return this;
|
||||
};
|
||||
|
||||
// Initialize options for this call
|
||||
var options = $.extend(
|
||||
{}/* new object */,
|
||||
$.fn.rating.options/* default options */,
|
||||
options || {} /* just-in-time options */
|
||||
);
|
||||
|
||||
// Allow multiple controls with the same name by making each call unique
|
||||
$.fn.rating.calls++;
|
||||
|
||||
// loop through each matched element
|
||||
this
|
||||
.not('.star-rating-applied')
|
||||
.addClass('star-rating-applied')
|
||||
.each(function(){
|
||||
|
||||
// Load control parameters / find context / etc
|
||||
var control, input = $(this);
|
||||
var eid = (this.name || 'unnamed-rating').replace(/\[|\]/g, '_').replace(/^\_+|\_+$/g,'');
|
||||
var context = $(this.form || document.body);
|
||||
|
||||
// FIX: http://code.google.com/p/jquery-star-rating-plugin/issues/detail?id=23
|
||||
var raters = context.data('rating');
|
||||
if(!raters || raters.call!=$.fn.rating.calls) raters = { count:0, call:$.fn.rating.calls };
|
||||
var rater = raters[eid] || context.data('rating'+eid);
|
||||
|
||||
// if rater is available, verify that the control still exists
|
||||
if(rater) control = rater.data('rating');
|
||||
|
||||
if(rater && control)//{// save a byte!
|
||||
// add star to control if rater is available and the same control still exists
|
||||
control.count++;
|
||||
|
||||
//}// save a byte!
|
||||
else{
|
||||
// create new control if first star or control element was removed/replaced
|
||||
|
||||
// Initialize options for this rater
|
||||
control = $.extend(
|
||||
{}/* new object */,
|
||||
options || {} /* current call options */,
|
||||
($.metadata? input.metadata(): ($.meta?input.data():null)) || {}, /* metadata options */
|
||||
{ count:0, stars: [], inputs: [] }
|
||||
);
|
||||
|
||||
// increment number of rating controls
|
||||
control.serial = raters.count++;
|
||||
|
||||
// create rating element
|
||||
rater = $('<span class="star-rating-control"/>');
|
||||
input.before(rater);
|
||||
|
||||
// Mark element for initialization (once all stars are ready)
|
||||
rater.addClass('rating-to-be-drawn');
|
||||
|
||||
// Accept readOnly setting from 'disabled' property
|
||||
if(input.attr('disabled') || input.hasClass('disabled')) control.readOnly = true;
|
||||
|
||||
// Accept required setting from class property (class='required')
|
||||
if(input.hasClass('required')) control.required = true;
|
||||
|
||||
// Create 'cancel' button
|
||||
rater.append(
|
||||
control.cancel = $('<div class="rating-cancel"><a title="' + control.cancel + '">' + control.cancelValue + '</a></div>')
|
||||
.on('mouseover',function(){
|
||||
$(this).rating('drain');
|
||||
$(this).addClass('star-rating-hover');
|
||||
//$(this).rating('focus');
|
||||
})
|
||||
.on('mouseout',function(){
|
||||
$(this).rating('draw');
|
||||
$(this).removeClass('star-rating-hover');
|
||||
//$(this).rating('blur');
|
||||
})
|
||||
.on('click',function(){
|
||||
$(this).rating('select');
|
||||
})
|
||||
.data('rating', control)
|
||||
);
|
||||
|
||||
}; // first element of group
|
||||
|
||||
// insert rating star (thanks Jan Fanslau rev125 for blind support https://code.google.com/p/jquery-star-rating-plugin/issues/detail?id=125)
|
||||
var star = $('<div role="text" aria-label="'+ this.title +'" class="star-rating rater-'+ control.serial +'"><a title="' + (this.title || this.value) + '">' + this.value + '</a></div>');
|
||||
rater.append(star);
|
||||
|
||||
// inherit attributes from input element
|
||||
if(this.id) star.attr('id', this.id);
|
||||
if(this.className) star.addClass(this.className);
|
||||
|
||||
// Half-stars?
|
||||
if(control.half) control.split = 2;
|
||||
|
||||
// Prepare division control
|
||||
if(typeof control.split=='number' && control.split>0){
|
||||
var stw = ($.fn.width ? star.width() : 0) || control.starWidth;
|
||||
var spi = (control.count % control.split), spw = Math.floor(stw/control.split);
|
||||
star
|
||||
// restrict star's width and hide overflow (already in CSS)
|
||||
.width(spw)
|
||||
// move the star left by using a negative margin
|
||||
// this is work-around to IE's stupid box model (position:relative doesn't work)
|
||||
.find('a').css({ 'margin-left':'-'+ (spi*spw) +'px' })
|
||||
};
|
||||
|
||||
// readOnly?
|
||||
if(control.readOnly)//{ //save a byte!
|
||||
// Mark star as readOnly so user can customize display
|
||||
star.addClass('star-rating-readonly');
|
||||
//} //save a byte!
|
||||
else//{ //save a byte!
|
||||
// Enable hover css effects
|
||||
star.addClass('star-rating-live')
|
||||
// Attach mouse events
|
||||
.on('mouseover',function(){
|
||||
$(this).rating('fill');
|
||||
$(this).rating('focus');
|
||||
})
|
||||
.on('mouseout',function(){
|
||||
$(this).rating('draw');
|
||||
$(this).rating('blur');
|
||||
})
|
||||
.on('click',function(){
|
||||
$(this).rating('select');
|
||||
})
|
||||
;
|
||||
//}; //save a byte!
|
||||
|
||||
// set current selection
|
||||
if(this.checked) control.current = star;
|
||||
|
||||
// set current select for links
|
||||
if(this.nodeName=="A"){
|
||||
if($(this).hasClass('selected'))
|
||||
control.current = star;
|
||||
};
|
||||
|
||||
// hide input element
|
||||
input.hide();
|
||||
|
||||
// backward compatibility, form element to plugin
|
||||
input.on('change.rating',function(event){
|
||||
if(event.selfTriggered) return false;
|
||||
$(this).rating('select');
|
||||
});
|
||||
|
||||
// attach reference to star to input element and vice-versa
|
||||
star.data('rating.input', input.data('rating.star', star));
|
||||
|
||||
// store control information in form (or body when form not available)
|
||||
control.stars[control.stars.length] = star[0];
|
||||
control.inputs[control.inputs.length] = input[0];
|
||||
control.rater = raters[eid] = rater;
|
||||
control.context = context;
|
||||
|
||||
input.data('rating', control);
|
||||
rater.data('rating', control);
|
||||
star.data('rating', control);
|
||||
context.data('rating', raters);
|
||||
context.data('rating'+eid, rater); // required for ajax forms
|
||||
}); // each element
|
||||
|
||||
// Initialize ratings (first draw)
|
||||
$('.rating-to-be-drawn').rating('draw').removeClass('rating-to-be-drawn');
|
||||
|
||||
return this; // don't break the chain...
|
||||
};
|
||||
|
||||
/*--------------------------------------------------------*/
|
||||
|
||||
/*
|
||||
### Core functionality and API ###
|
||||
*/
|
||||
$.extend($.fn.rating, {
|
||||
// Used to append a unique serial number to internal control ID
|
||||
// each time the plugin is invoked so same name controls can co-exist
|
||||
calls: 0,
|
||||
|
||||
focus: function(){
|
||||
var control = this.data('rating'); if(!control) return this;
|
||||
if(!control.focus) return this; // quick fail if not required
|
||||
// find data for event
|
||||
var input = $(this).data('rating.input') || $( this.tagName=='INPUT' ? this : null );
|
||||
// focus handler, as requested by focusdigital.co.uk
|
||||
if(control.focus) control.focus.apply(input[0], [input.val(), $('a', input.data('rating.star'))[0]]);
|
||||
}, // $.fn.rating.focus
|
||||
|
||||
blur: function(){
|
||||
var control = this.data('rating'); if(!control) return this;
|
||||
if(!control.blur) return this; // quick fail if not required
|
||||
// find data for event
|
||||
var input = $(this).data('rating.input') || $( this.tagName=='INPUT' ? this : null );
|
||||
// blur handler, as requested by focusdigital.co.uk
|
||||
if(control.blur) control.blur.apply(input[0], [input.val(), $('a', input.data('rating.star'))[0]]);
|
||||
}, // $.fn.rating.blur
|
||||
|
||||
fill: function(){ // fill to the current mouse position.
|
||||
var control = this.data('rating'); if(!control) return this;
|
||||
// do not execute when control is in read-only mode
|
||||
if(control.readOnly) return;
|
||||
// Reset all stars and highlight them up to this element
|
||||
this.rating('drain');
|
||||
this.prevAll().addBack().filter('.rater-'+ control.serial).addClass('star-rating-hover');
|
||||
},// $.fn.rating.fill
|
||||
|
||||
drain: function() { // drain all the stars.
|
||||
var control = this.data('rating'); if(!control) return this;
|
||||
// do not execute when control is in read-only mode
|
||||
if(control.readOnly) return;
|
||||
// Reset all stars
|
||||
control.rater.children().filter('.rater-'+ control.serial).removeClass('star-rating-on').removeClass('star-rating-hover');
|
||||
},// $.fn.rating.drain
|
||||
|
||||
draw: function(){ // set value and stars to reflect current selection
|
||||
var control = this.data('rating'); if(!control) return this;
|
||||
// Clear all stars
|
||||
this.rating('drain');
|
||||
// Set control value
|
||||
var current = $( control.current );//? control.current.data('rating.input') : null );
|
||||
var starson = current.length ? current.prevAll().addBack().filter('.rater-'+ control.serial) : null;
|
||||
if(starson) starson.addClass('star-rating-on');
|
||||
// Show/hide 'cancel' button
|
||||
control.cancel[control.readOnly || control.required?'hide':'show']();
|
||||
// Add/remove read-only classes to remove hand pointer
|
||||
this.siblings()[control.readOnly?'addClass':'removeClass']('star-rating-readonly');
|
||||
},// $.fn.rating.draw
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
select: function(value,wantCallBack){ // select a value
|
||||
var control = this.data('rating'); if(!control) return this;
|
||||
// do not execute when control is in read-only mode
|
||||
if(control.readOnly) return;
|
||||
// clear selection
|
||||
control.current = null;
|
||||
// programmatically (based on user input)
|
||||
if(typeof value!='undefined' || this.length>1){
|
||||
// select by index (0 based)
|
||||
if(typeof value=='number')
|
||||
return $(control.stars[value]).rating('select',undefined,wantCallBack);
|
||||
// select by literal value (must be passed as a string
|
||||
if(typeof value=='string'){
|
||||
//return
|
||||
$.each(control.stars, function(){
|
||||
//console.log($(this).data('rating.input'), $(this).data('rating.input').val(), value, $(this).data('rating.input').val()==value?'BINGO!':'');
|
||||
if($(this).data('rating.input').val()==value) $(this).rating('select',undefined,wantCallBack);
|
||||
});
|
||||
// don't break the chain
|
||||
return this;
|
||||
};
|
||||
}
|
||||
else{
|
||||
control.current = this[0].tagName=='INPUT' ?
|
||||
this.data('rating.star') :
|
||||
(this.is('.rater-'+ control.serial) ? this : null);
|
||||
};
|
||||
// Update rating control state
|
||||
this.data('rating', control);
|
||||
// Update display
|
||||
this.rating('draw');
|
||||
// find current input and its sibblings
|
||||
var current = $( control.current ? control.current.data('rating.input') : null );
|
||||
var lastipt = $( control.inputs ).filter(':checked');
|
||||
var deadipt = $( control.inputs ).not(current);
|
||||
// check and uncheck elements as required
|
||||
deadipt.prop('checked',false);//.removeAttr('checked');
|
||||
current.prop('checked',true);//.attr('checked','checked');
|
||||
// trigger change on current or last selected input
|
||||
$(current.length? current : lastipt ).trigger({ type:'change', selfTriggered:true });
|
||||
// click callback, as requested here: http://plugins.jquery.com/node/1655
|
||||
if((wantCallBack || wantCallBack == undefined) && control.callback) control.callback.apply(current[0], [current.val(), $('a', control.current)[0]]);// callback event
|
||||
// don't break the chain
|
||||
return this;
|
||||
},// $.fn.rating.select
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
readOnly: function(toggle, disable){ // make the control read-only (still submits value)
|
||||
var control = this.data('rating'); if(!control) return this;
|
||||
// setread-only status
|
||||
control.readOnly = toggle || toggle==undefined ? true : false;
|
||||
// enable/disable control value submission
|
||||
if(disable) $(control.inputs).attr("disabled", "disabled");
|
||||
else $(control.inputs).removeAttr("disabled");
|
||||
// Update rating control state
|
||||
this.data('rating', control);
|
||||
// Update display
|
||||
this.rating('draw');
|
||||
},// $.fn.rating.readOnly
|
||||
|
||||
disable: function(){ // make read-only and never submit value
|
||||
this.rating('readOnly', true, true);
|
||||
},// $.fn.rating.disable
|
||||
|
||||
enable: function(){ // make read/write and submit value
|
||||
this.rating('readOnly', false, false);
|
||||
}// $.fn.rating.select
|
||||
|
||||
});
|
||||
|
||||
/*--------------------------------------------------------*/
|
||||
|
||||
/*
|
||||
### Default Settings ###
|
||||
eg.: You can override default control like this:
|
||||
$.fn.rating.options.cancel = 'Clear';
|
||||
*/
|
||||
$.fn.rating.options = { //$.extend($.fn.rating, { options: {
|
||||
cancel: 'Cancel Rating', // advisory title for the 'cancel' link
|
||||
cancelValue: '', // value to submit when user click the 'cancel' link
|
||||
split: 0, // split the star into how many parts?
|
||||
|
||||
// Width of star image in case the plugin can't work it out. This can happen if
|
||||
// the jQuery.dimensions plugin is not available OR the image is hidden at installation
|
||||
starWidth: 16//,
|
||||
|
||||
//NB.: These don't need to be pre-defined (can be undefined/null) so let's save some code!
|
||||
//half: false, // just a shortcut to control.split = 2
|
||||
//required: false, // disables the 'cancel' button so user can only select one of the specified values
|
||||
//readOnly: false, // disable rating plugin interaction/ values cannot be.one('change', //focus: function(){}, // executed when stars are focused
|
||||
//blur: function(){}, // executed when stars are focused
|
||||
//callback: function(){}, // executed when a star is clicked
|
||||
}; //} });
|
||||
|
||||
/*--------------------------------------------------------*/
|
||||
|
||||
|
||||
// auto-initialize plugin
|
||||
$(function(){
|
||||
$('input[type=radio].star').rating();
|
||||
});
|
||||
|
||||
|
||||
/*# AVOID COLLISIONS #*/
|
||||
})(jQuery);
|
||||
/*# AVOID COLLISIONS #*/
|
110
yii/assets/7b3570a4/jquery.treeview.async.js
Normal file
@ -0,0 +1,110 @@
|
||||
/*
|
||||
* Async Treeview 0.1 - Lazy-loading extension for Treeview
|
||||
*
|
||||
* http://bassistance.de/jquery-plugins/jquery-plugin-treeview/
|
||||
*
|
||||
* Copyright (c) 2007 Jörn Zaefferer
|
||||
*
|
||||
* Dual licensed under the MIT and GPL licenses:
|
||||
* http://www.opensource.org/licenses/mit-license.php
|
||||
* http://www.gnu.org/licenses/gpl.html
|
||||
*
|
||||
* Revision: $Id$
|
||||
*
|
||||
*/
|
||||
|
||||
;(function($) {
|
||||
|
||||
function load(settings, root, child, container) {
|
||||
function createNode(parent) {
|
||||
var current = $("<li/>").attr("id", this.id || "").html("<span>" + this.text + "</span>").appendTo(parent);
|
||||
if (this.classes) {
|
||||
current.children("span").addClass(this.classes);
|
||||
}
|
||||
if (this.expanded) {
|
||||
current.addClass("open");
|
||||
}
|
||||
if (this.hasChildren || this.children && this.children.length) {
|
||||
var branch = $("<ul/>").appendTo(current);
|
||||
if (this.hasChildren) {
|
||||
current.addClass("hasChildren");
|
||||
createNode.call({
|
||||
classes: "placeholder",
|
||||
text: " ",
|
||||
children:[]
|
||||
}, branch);
|
||||
}
|
||||
if (this.children && this.children.length) {
|
||||
$.each(this.children, createNode, [branch])
|
||||
}
|
||||
}
|
||||
}
|
||||
$.ajax($.extend(true, {
|
||||
url: settings.url,
|
||||
dataType: "json",
|
||||
data: {
|
||||
root: root
|
||||
},
|
||||
success: function(response) {
|
||||
child.empty();
|
||||
$.each(response, createNode, [child]);
|
||||
$(container).treeview({add: child});
|
||||
}
|
||||
}, settings.ajax));
|
||||
/*
|
||||
$.getJSON(settings.url, {root: root}, function(response) {
|
||||
function createNode(parent) {
|
||||
var current = $("<li/>").attr("id", this.id || "").html("<span>" + this.text + "</span>").appendTo(parent);
|
||||
if (this.classes) {
|
||||
current.children("span").addClass(this.classes);
|
||||
}
|
||||
if (this.expanded) {
|
||||
current.addClass("open");
|
||||
}
|
||||
if (this.hasChildren || this.children && this.children.length) {
|
||||
var branch = $("<ul/>").appendTo(current);
|
||||
if (this.hasChildren) {
|
||||
current.addClass("hasChildren");
|
||||
createNode.call({
|
||||
classes: "placeholder",
|
||||
text: " ",
|
||||
children:[]
|
||||
}, branch);
|
||||
}
|
||||
if (this.children && this.children.length) {
|
||||
$.each(this.children, createNode, [branch])
|
||||
}
|
||||
}
|
||||
}
|
||||
child.empty();
|
||||
$.each(response, createNode, [child]);
|
||||
$(container).treeview({add: child});
|
||||
});
|
||||
*/
|
||||
}
|
||||
|
||||
var proxied = $.fn.treeview;
|
||||
$.fn.treeview = function(settings) {
|
||||
if (!settings.url) {
|
||||
return proxied.apply(this, arguments);
|
||||
}
|
||||
var container = this;
|
||||
if (!container.children().size())
|
||||
load(settings, "source", this, container);
|
||||
var userToggle = settings.toggle;
|
||||
return proxied.call(this, $.extend({}, settings, {
|
||||
collapsed: true,
|
||||
toggle: function() {
|
||||
var $this = $(this);
|
||||
if ($this.hasClass("hasChildren")) {
|
||||
var childList = $this.removeClass("hasChildren").find("ul");
|
||||
load(settings, this.id, childList, container);
|
||||
}
|
||||
if (userToggle) {
|
||||
userToggle.apply(this, arguments);
|
||||
}
|
||||
}
|
||||
}));
|
||||
};
|
||||
|
||||
})(jQuery);
|
37
yii/assets/7b3570a4/jquery.treeview.edit.js
Normal file
@ -0,0 +1,37 @@
|
||||
(function($) {
|
||||
var CLASSES = $.treeview.classes;
|
||||
var proxied = $.fn.treeview;
|
||||
$.fn.treeview = function(settings) {
|
||||
settings = $.extend({}, settings);
|
||||
if (settings.add) {
|
||||
return this.trigger("add", [settings.add]);
|
||||
}
|
||||
if (settings.remove) {
|
||||
return this.trigger("remove", [settings.remove]);
|
||||
}
|
||||
return proxied.apply(this, arguments).bind("add", function(event, branches) {
|
||||
$(branches).prev()
|
||||
.removeClass(CLASSES.last)
|
||||
.removeClass(CLASSES.lastCollapsable)
|
||||
.removeClass(CLASSES.lastExpandable)
|
||||
.find(">.hitarea")
|
||||
.removeClass(CLASSES.lastCollapsableHitarea)
|
||||
.removeClass(CLASSES.lastExpandableHitarea);
|
||||
$(branches).find("li").andSelf().prepareBranches(settings).applyClasses(settings, $(this).data("toggler"));
|
||||
}).bind("remove", function(event, branches) {
|
||||
var prev = $(branches).prev();
|
||||
var parent = $(branches).parent();
|
||||
$(branches).remove();
|
||||
prev.filter(":last-child").addClass(CLASSES.last)
|
||||
.filter("." + CLASSES.expandable).replaceClass(CLASSES.last, CLASSES.lastExpandable).end()
|
||||
.find(">.hitarea").replaceClass(CLASSES.expandableHitarea, CLASSES.lastExpandableHitarea).end()
|
||||
.filter("." + CLASSES.collapsable).replaceClass(CLASSES.last, CLASSES.lastCollapsable).end()
|
||||
.find(">.hitarea").replaceClass(CLASSES.collapsableHitarea, CLASSES.lastCollapsableHitarea);
|
||||
if (parent.is(":not(:has(>))") && parent[0] != this) {
|
||||
parent.parent().removeClass(CLASSES.collapsable).removeClass(CLASSES.expandable);
|
||||
parent.siblings(".hitarea").andSelf().remove();
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
})(jQuery);
|
256
yii/assets/7b3570a4/jquery.treeview.js
Normal file
@ -0,0 +1,256 @@
|
||||
/*
|
||||
* Treeview 1.5pre - jQuery plugin to hide and show branches of a tree
|
||||
*
|
||||
* http://bassistance.de/jquery-plugins/jquery-plugin-treeview/
|
||||
* http://docs.jquery.com/Plugins/Treeview
|
||||
*
|
||||
* Copyright (c) 2007 Jörn Zaefferer
|
||||
*
|
||||
* Dual licensed under the MIT and GPL licenses:
|
||||
* http://www.opensource.org/licenses/mit-license.php
|
||||
* http://www.gnu.org/licenses/gpl.html
|
||||
*
|
||||
* Revision: $Id: jquery.treeview.js 5759 2008-07-01 07:50:28Z joern.zaefferer $
|
||||
*
|
||||
*/
|
||||
|
||||
;(function($) {
|
||||
|
||||
// TODO rewrite as a widget, removing all the extra plugins
|
||||
$.extend($.fn, {
|
||||
swapClass: function(c1, c2) {
|
||||
var c1Elements = this.filter('.' + c1);
|
||||
this.filter('.' + c2).removeClass(c2).addClass(c1);
|
||||
c1Elements.removeClass(c1).addClass(c2);
|
||||
return this;
|
||||
},
|
||||
replaceClass: function(c1, c2) {
|
||||
return this.filter('.' + c1).removeClass(c1).addClass(c2).end();
|
||||
},
|
||||
hoverClass: function(className) {
|
||||
className = className || "hover";
|
||||
return this.hover(function() {
|
||||
$(this).addClass(className);
|
||||
}, function() {
|
||||
$(this).removeClass(className);
|
||||
});
|
||||
},
|
||||
heightToggle: function(animated, callback) {
|
||||
animated ?
|
||||
this.animate({ height: "toggle" }, animated, callback) :
|
||||
this.each(function(){
|
||||
jQuery(this)[ jQuery(this).is(":hidden") ? "show" : "hide" ]();
|
||||
if(callback)
|
||||
callback.apply(this, arguments);
|
||||
});
|
||||
},
|
||||
heightHide: function(animated, callback) {
|
||||
if (animated) {
|
||||
this.animate({ height: "hide" }, animated, callback);
|
||||
} else {
|
||||
this.hide();
|
||||
if (callback)
|
||||
this.each(callback);
|
||||
}
|
||||
},
|
||||
prepareBranches: function(settings) {
|
||||
if (!settings.prerendered) {
|
||||
// mark last tree items
|
||||
this.filter(":last-child:not(ul)").addClass(CLASSES.last);
|
||||
// collapse whole tree, or only those marked as closed, anyway except those marked as open
|
||||
this.filter((settings.collapsed ? "" : "." + CLASSES.closed) + ":not(." + CLASSES.open + ")").find(">ul").hide();
|
||||
}
|
||||
// return all items with sublists
|
||||
return this.filter(":has(>ul)");
|
||||
},
|
||||
applyClasses: function(settings, toggler) {
|
||||
// TODO use event delegation
|
||||
this.filter(":has(>ul):not(:has(>a))").find(">span").unbind("click.treeview").bind("click.treeview", function(event) {
|
||||
// don't handle click events on children, eg. checkboxes
|
||||
if ( this == event.target )
|
||||
toggler.apply($(this).next());
|
||||
}).add( $("a", this) ).hoverClass();
|
||||
|
||||
if (!settings.prerendered) {
|
||||
// handle closed ones first
|
||||
this.filter(":has(>ul:hidden)")
|
||||
.addClass(CLASSES.expandable)
|
||||
.replaceClass(CLASSES.last, CLASSES.lastExpandable);
|
||||
|
||||
// handle open ones
|
||||
this.not(":has(>ul:hidden)")
|
||||
.addClass(CLASSES.collapsable)
|
||||
.replaceClass(CLASSES.last, CLASSES.lastCollapsable);
|
||||
|
||||
// create hitarea if not present
|
||||
var hitarea = this.find("div." + CLASSES.hitarea);
|
||||
if (!hitarea.length)
|
||||
hitarea = this.prepend("<div class=\"" + CLASSES.hitarea + "\"/>").find("div." + CLASSES.hitarea);
|
||||
hitarea.removeClass().addClass(CLASSES.hitarea).each(function() {
|
||||
var classes = "";
|
||||
$.each($(this).parent().attr("class").split(" "), function() {
|
||||
classes += this + "-hitarea ";
|
||||
});
|
||||
$(this).addClass( classes );
|
||||
})
|
||||
}
|
||||
|
||||
// apply event to hitarea
|
||||
this.find("div." + CLASSES.hitarea).click( toggler );
|
||||
},
|
||||
treeview: function(settings) {
|
||||
|
||||
settings = $.extend({
|
||||
cookieId: "treeview"
|
||||
}, settings);
|
||||
|
||||
if ( settings.toggle ) {
|
||||
var callback = settings.toggle;
|
||||
settings.toggle = function() {
|
||||
return callback.apply($(this).parent()[0], arguments);
|
||||
};
|
||||
}
|
||||
|
||||
// factory for treecontroller
|
||||
function treeController(tree, control) {
|
||||
// factory for click handlers
|
||||
function handler(filter) {
|
||||
return function() {
|
||||
// reuse toggle event handler, applying the elements to toggle
|
||||
// start searching for all hitareas
|
||||
toggler.apply( $("div." + CLASSES.hitarea, tree).filter(function() {
|
||||
// for plain toggle, no filter is provided, otherwise we need to check the parent element
|
||||
return filter ? $(this).parent("." + filter).length : true;
|
||||
}) );
|
||||
return false;
|
||||
};
|
||||
}
|
||||
// click on first element to collapse tree
|
||||
$("a:eq(0)", control).click( handler(CLASSES.collapsable) );
|
||||
// click on second to expand tree
|
||||
$("a:eq(1)", control).click( handler(CLASSES.expandable) );
|
||||
// click on third to toggle tree
|
||||
$("a:eq(2)", control).click( handler() );
|
||||
}
|
||||
|
||||
// handle toggle event
|
||||
function toggler() {
|
||||
$(this)
|
||||
.parent()
|
||||
// swap classes for hitarea
|
||||
.find(">.hitarea")
|
||||
.swapClass( CLASSES.collapsableHitarea, CLASSES.expandableHitarea )
|
||||
.swapClass( CLASSES.lastCollapsableHitarea, CLASSES.lastExpandableHitarea )
|
||||
.end()
|
||||
// swap classes for parent li
|
||||
.swapClass( CLASSES.collapsable, CLASSES.expandable )
|
||||
.swapClass( CLASSES.lastCollapsable, CLASSES.lastExpandable )
|
||||
// find child lists
|
||||
.find( ">ul" )
|
||||
// toggle them
|
||||
.heightToggle( settings.animated, settings.toggle );
|
||||
if ( settings.unique ) {
|
||||
$(this).parent()
|
||||
.siblings()
|
||||
// swap classes for hitarea
|
||||
.find(">.hitarea")
|
||||
.replaceClass( CLASSES.collapsableHitarea, CLASSES.expandableHitarea )
|
||||
.replaceClass( CLASSES.lastCollapsableHitarea, CLASSES.lastExpandableHitarea )
|
||||
.end()
|
||||
.replaceClass( CLASSES.collapsable, CLASSES.expandable )
|
||||
.replaceClass( CLASSES.lastCollapsable, CLASSES.lastExpandable )
|
||||
.find( ">ul" )
|
||||
.heightHide( settings.animated, settings.toggle );
|
||||
}
|
||||
}
|
||||
this.data("toggler", toggler);
|
||||
|
||||
function serialize() {
|
||||
function binary(arg) {
|
||||
return arg ? 1 : 0;
|
||||
}
|
||||
var data = [];
|
||||
branches.each(function(i, e) {
|
||||
data[i] = $(e).is(":has(>ul:visible)") ? 1 : 0;
|
||||
});
|
||||
$.cookie(settings.cookieId, data.join(""), settings.cookieOptions );
|
||||
}
|
||||
|
||||
function deserialize() {
|
||||
var stored = $.cookie(settings.cookieId);
|
||||
if ( stored ) {
|
||||
var data = stored.split("");
|
||||
branches.each(function(i, e) {
|
||||
$(e).find(">ul")[ parseInt(data[i]) ? "show" : "hide" ]();
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
// add treeview class to activate styles
|
||||
this.addClass("treeview");
|
||||
|
||||
// prepare branches and find all tree items with child lists
|
||||
var branches = this.find("li").prepareBranches(settings);
|
||||
|
||||
switch(settings.persist) {
|
||||
case "cookie":
|
||||
var toggleCallback = settings.toggle;
|
||||
settings.toggle = function() {
|
||||
serialize();
|
||||
if (toggleCallback) {
|
||||
toggleCallback.apply(this, arguments);
|
||||
}
|
||||
};
|
||||
deserialize();
|
||||
break;
|
||||
case "location":
|
||||
var current = this.find("a").filter(function() {
|
||||
return this.href.toLowerCase() == location.href.toLowerCase();
|
||||
});
|
||||
if ( current.length ) {
|
||||
// TODO update the open/closed classes
|
||||
var items = current.addClass("selected").parents("ul, li").add( current.next() ).show();
|
||||
if (settings.prerendered) {
|
||||
// if prerendered is on, replicate the basic class swapping
|
||||
items.filter("li")
|
||||
.swapClass( CLASSES.collapsable, CLASSES.expandable )
|
||||
.swapClass( CLASSES.lastCollapsable, CLASSES.lastExpandable )
|
||||
.find(">.hitarea")
|
||||
.swapClass( CLASSES.collapsableHitarea, CLASSES.expandableHitarea )
|
||||
.swapClass( CLASSES.lastCollapsableHitarea, CLASSES.lastExpandableHitarea );
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
branches.applyClasses(settings, toggler);
|
||||
|
||||
// if control option is set, create the treecontroller and show it
|
||||
if ( settings.control ) {
|
||||
treeController(this, settings.control);
|
||||
$(settings.control).show();
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
});
|
||||
|
||||
// classes used by the plugin
|
||||
// need to be styled via external stylesheet, see first example
|
||||
$.treeview = {};
|
||||
var CLASSES = ($.treeview.classes = {
|
||||
open: "open",
|
||||
closed: "closed",
|
||||
expandable: "expandable",
|
||||
expandableHitarea: "expandable-hitarea",
|
||||
lastExpandableHitarea: "lastExpandable-hitarea",
|
||||
collapsable: "collapsable",
|
||||
collapsableHitarea: "collapsable-hitarea",
|
||||
lastCollapsableHitarea: "lastCollapsable-hitarea",
|
||||
lastCollapsable: "lastCollapsable",
|
||||
lastExpandable: "lastExpandable",
|
||||
last: "last",
|
||||
hitarea: "hitarea"
|
||||
});
|
||||
|
||||
})(jQuery);
|
52
yii/assets/7b3570a4/jquery.yii.js
Normal file
@ -0,0 +1,52 @@
|
||||
/**
|
||||
* jQuery Yii plugin file.
|
||||
*
|
||||
* @author Qiang Xue <qiang.xue@gmail.com>
|
||||
* @link http://www.yiiframework.com/
|
||||
* @copyright 2008-2010 Yii Software LLC
|
||||
* @license http://www.yiiframework.com/license/
|
||||
*/
|
||||
|
||||
;(function($) {
|
||||
|
||||
$.yii = {
|
||||
version : '1.0',
|
||||
|
||||
submitForm : function (element, url, params) {
|
||||
var f = $(element).parents('form')[0];
|
||||
if (!f) {
|
||||
f = document.createElement('form');
|
||||
f.style.display = 'none';
|
||||
element.parentNode.appendChild(f);
|
||||
f.method = 'POST';
|
||||
}
|
||||
if (typeof url == 'string' && url != '') {
|
||||
f.action = url;
|
||||
}
|
||||
if (element.target != null) {
|
||||
f.target = element.target;
|
||||
}
|
||||
|
||||
var inputs = [];
|
||||
$.each(params, function(name, value) {
|
||||
var input = document.createElement("input");
|
||||
input.setAttribute("type", "hidden");
|
||||
input.setAttribute("name", name);
|
||||
input.setAttribute("value", value);
|
||||
f.appendChild(input);
|
||||
inputs.push(input);
|
||||
});
|
||||
|
||||
// remember who triggers the form submission
|
||||
// this is used by jquery.yiiactiveform.js
|
||||
$(f).data('submitObject', $(element));
|
||||
|
||||
$(f).trigger('submit');
|
||||
|
||||
$.each(inputs, function() {
|
||||
f.removeChild(this);
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
})(jQuery);
|
438
yii/assets/7b3570a4/jquery.yiiactiveform.js
Normal file
@ -0,0 +1,438 @@
|
||||
/**
|
||||
* jQuery yiiactiveform plugin file.
|
||||
*
|
||||
* @author Qiang Xue <qiang.xue@gmail.com>
|
||||
* @link http://www.yiiframework.com/
|
||||
* @copyright 2008-2010 Yii Software LLC
|
||||
* @license http://www.yiiframework.com/license/
|
||||
* @since 1.1.1
|
||||
*/
|
||||
|
||||
(function ($) {
|
||||
/*
|
||||
* returns the value of the CActiveForm input field
|
||||
* performs additional checks to get proper values for checkbox / radiobutton / checkBoxList / radioButtonList
|
||||
* @param o object the jQuery object of the input element
|
||||
*/
|
||||
var getAFValue = function (o) {
|
||||
var type,
|
||||
c = [];
|
||||
if (!o.length) {
|
||||
return undefined;
|
||||
}
|
||||
if (o[0].tagName.toLowerCase() === 'span') {
|
||||
o.find(':checked').each(function () {
|
||||
c.push(this.value);
|
||||
});
|
||||
return c.join(',');
|
||||
}
|
||||
type = o.attr('type');
|
||||
if (type === 'checkbox' || type === 'radio') {
|
||||
return o.filter(':checked').val();
|
||||
} else {
|
||||
return o.val();
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* yiiactiveform set function.
|
||||
* @param options map settings for the active form plugin. Please see {@link CActiveForm::options} for availablel options.
|
||||
*/
|
||||
$.fn.yiiactiveform = function (options) {
|
||||
return this.each(function () {
|
||||
var settings = $.extend({}, $.fn.yiiactiveform.defaults, options || {}),
|
||||
$form = $(this);
|
||||
|
||||
if (settings.validationUrl === undefined) {
|
||||
settings.validationUrl = $form.attr('action');
|
||||
}
|
||||
$.each(settings.attributes, function (i) {
|
||||
this.value = getAFValue($form.find('#' + this.inputID));
|
||||
settings.attributes[i] = $.extend({}, {
|
||||
validationDelay: settings.validationDelay,
|
||||
validateOnChange: settings.validateOnChange,
|
||||
validateOnType: settings.validateOnType,
|
||||
hideErrorMessage: settings.hideErrorMessage,
|
||||
inputContainer: settings.inputContainer,
|
||||
errorCssClass: settings.errorCssClass,
|
||||
successCssClass: settings.successCssClass,
|
||||
beforeValidateAttribute: settings.beforeValidateAttribute,
|
||||
afterValidateAttribute: settings.afterValidateAttribute,
|
||||
validatingCssClass: settings.validatingCssClass
|
||||
}, this);
|
||||
});
|
||||
$form.data('settings', settings);
|
||||
|
||||
settings.submitting = false; // whether it is waiting for ajax submission result
|
||||
var validate = function (attribute, forceValidate) {
|
||||
if (forceValidate) {
|
||||
attribute.status = 2;
|
||||
}
|
||||
$.each(settings.attributes, function () {
|
||||
if (this.value !== getAFValue($form.find('#' + this.inputID))) {
|
||||
this.status = 2;
|
||||
forceValidate = true;
|
||||
}
|
||||
});
|
||||
if (!forceValidate) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (settings.timer !== undefined) {
|
||||
clearTimeout(settings.timer);
|
||||
}
|
||||
settings.timer = setTimeout(function () {
|
||||
if (settings.submitting || $form.is(':hidden')) {
|
||||
return;
|
||||
}
|
||||
if (attribute.beforeValidateAttribute === undefined || attribute.beforeValidateAttribute($form, attribute)) {
|
||||
$.each(settings.attributes, function () {
|
||||
if (this.status === 2) {
|
||||
this.status = 3;
|
||||
$.fn.yiiactiveform.getInputContainer(this, $form).addClass(this.validatingCssClass);
|
||||
}
|
||||
});
|
||||
$.fn.yiiactiveform.validate($form, function (data) {
|
||||
var hasError = false;
|
||||
$.each(settings.attributes, function () {
|
||||
if (this.status === 2 || this.status === 3) {
|
||||
hasError = $.fn.yiiactiveform.updateInput(this, data, $form) || hasError;
|
||||
}
|
||||
});
|
||||
if (attribute.afterValidateAttribute !== undefined) {
|
||||
attribute.afterValidateAttribute($form, attribute, data, hasError);
|
||||
}
|
||||
});
|
||||
}
|
||||
}, attribute.validationDelay);
|
||||
};
|
||||
|
||||
$.each(settings.attributes, function (i, attribute) {
|
||||
if (this.validateOnChange) {
|
||||
$form.find('#' + this.inputID).change(function () {
|
||||
validate(attribute, false);
|
||||
}).blur(function () {
|
||||
if (attribute.status !== 2 && attribute.status !== 3) {
|
||||
validate(attribute, !attribute.status);
|
||||
}
|
||||
});
|
||||
}
|
||||
if (this.validateOnType) {
|
||||
$form.find('#' + this.inputID).keyup(function () {
|
||||
if (attribute.value !== getAFValue($(this))) {
|
||||
validate(attribute, false);
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
if (settings.validateOnSubmit) {
|
||||
$form.on('mouseup keyup', ':submit', function () {
|
||||
$form.data('submitObject', $(this));
|
||||
});
|
||||
var validated = false;
|
||||
$form.submit(function () {
|
||||
if (validated) {
|
||||
validated = false;
|
||||
return true;
|
||||
}
|
||||
if (settings.timer !== undefined) {
|
||||
clearTimeout(settings.timer);
|
||||
}
|
||||
settings.submitting = true;
|
||||
if (settings.beforeValidate === undefined || settings.beforeValidate($form)) {
|
||||
$.fn.yiiactiveform.validate($form, function (data) {
|
||||
var hasError = false;
|
||||
$.each(settings.attributes, function () {
|
||||
hasError = $.fn.yiiactiveform.updateInput(this, data, $form) || hasError;
|
||||
});
|
||||
$.fn.yiiactiveform.updateSummary($form, data);
|
||||
if (settings.afterValidate === undefined || settings.afterValidate($form, data, hasError)) {
|
||||
if (!hasError) {
|
||||
validated = true;
|
||||
var $button = $form.data('submitObject') || $form.find(':submit:first');
|
||||
// TODO: if the submission is caused by "change" event, it will not work
|
||||
if ($button.length) {
|
||||
$button.click();
|
||||
} else { // no submit button in the form
|
||||
$form.submit();
|
||||
}
|
||||
return;
|
||||
}
|
||||
}
|
||||
settings.submitting = false;
|
||||
});
|
||||
} else {
|
||||
settings.submitting = false;
|
||||
}
|
||||
return false;
|
||||
});
|
||||
}
|
||||
|
||||
/*
|
||||
* In case of reseting the form we need to reset error messages
|
||||
* NOTE1: $form.reset - does not exist
|
||||
* NOTE2: $form.on('reset', ...) does not work
|
||||
*/
|
||||
$form.bind('reset', function () {
|
||||
/*
|
||||
* because we bind directly to a form reset event, not to a reset button (that could or could not exist),
|
||||
* when this function is executed form elements values have not been reset yet,
|
||||
* because of that we use the setTimeout
|
||||
*/
|
||||
setTimeout(function () {
|
||||
$.each(settings.attributes, function () {
|
||||
this.status = 0;
|
||||
var $error = $form.find('#' + this.errorID),
|
||||
$container = $.fn.yiiactiveform.getInputContainer(this, $form);
|
||||
|
||||
$container.removeClass(
|
||||
this.validatingCssClass + ' ' +
|
||||
this.errorCssClass + ' ' +
|
||||
this.successCssClass
|
||||
);
|
||||
|
||||
$error.html('').hide();
|
||||
|
||||
/*
|
||||
* without the setTimeout() we would get here the current entered value before the reset instead of the reseted value
|
||||
*/
|
||||
this.value = getAFValue($form.find('#' + this.inputID));
|
||||
});
|
||||
/*
|
||||
* If the form is submited (non ajax) with errors, labels and input gets the class 'error'
|
||||
*/
|
||||
$form.find('label, :input').each(function () {
|
||||
$(this).removeClass(settings.errorCss);
|
||||
});
|
||||
$('#' + settings.summaryID).hide().find('ul').html('');
|
||||
//.. set to initial focus on reset
|
||||
if (settings.focus !== undefined && !window.location.hash) {
|
||||
$form.find(settings.focus).focus();
|
||||
}
|
||||
}, 1);
|
||||
});
|
||||
|
||||
/*
|
||||
* set to initial focus
|
||||
*/
|
||||
if (settings.focus !== undefined && !window.location.hash) {
|
||||
$form.find(settings.focus).focus();
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* Returns the container element of the specified attribute.
|
||||
* @param attribute object the configuration for a particular attribute.
|
||||
* @param form the form jQuery object
|
||||
* @return jQuery the jQuery representation of the container
|
||||
*/
|
||||
$.fn.yiiactiveform.getInputContainer = function (attribute, form) {
|
||||
if (attribute.inputContainer === undefined) {
|
||||
return form.find('#' + attribute.inputID).closest('div');
|
||||
} else {
|
||||
return form.find(attribute.inputContainer).filter(':has("#' + attribute.inputID + '")');
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* updates the error message and the input container for a particular attribute.
|
||||
* @param attribute object the configuration for a particular attribute.
|
||||
* @param messages array the json data obtained from the ajax validation request
|
||||
* @param form the form jQuery object
|
||||
* @return boolean whether there is a validation error for the specified attribute
|
||||
*/
|
||||
$.fn.yiiactiveform.updateInput = function (attribute, messages, form) {
|
||||
attribute.status = 1;
|
||||
var $error, $container,
|
||||
hasError = false,
|
||||
$el = form.find('#' + attribute.inputID),
|
||||
errorCss = form.data('settings').errorCss;
|
||||
|
||||
if ($el.length) {
|
||||
hasError = messages !== null && $.isArray(messages[attribute.id]) && messages[attribute.id].length > 0;
|
||||
$error = form.find('#' + attribute.errorID);
|
||||
$container = $.fn.yiiactiveform.getInputContainer(attribute, form);
|
||||
|
||||
$container.removeClass(
|
||||
attribute.validatingCssClass + ' ' +
|
||||
attribute.errorCssClass + ' ' +
|
||||
attribute.successCssClass
|
||||
);
|
||||
$container.find('label, :input').each(function () {
|
||||
$(this).removeClass(errorCss);
|
||||
});
|
||||
|
||||
if (hasError) {
|
||||
$error.html(messages[attribute.id][0]);
|
||||
$container.addClass(attribute.errorCssClass);
|
||||
} else if (attribute.enableAjaxValidation || attribute.clientValidation) {
|
||||
$container.addClass(attribute.successCssClass);
|
||||
}
|
||||
if (!attribute.hideErrorMessage) {
|
||||
$error.toggle(hasError);
|
||||
}
|
||||
|
||||
attribute.value = getAFValue($el);
|
||||
}
|
||||
return hasError;
|
||||
};
|
||||
|
||||
/**
|
||||
* updates the error summary, if any.
|
||||
* @param form jquery the jquery representation of the form
|
||||
* @param messages array the json data obtained from the ajax validation request
|
||||
*/
|
||||
$.fn.yiiactiveform.updateSummary = function (form, messages) {
|
||||
var settings = $(form).data('settings'),
|
||||
content = '';
|
||||
if (settings.summaryID === undefined) {
|
||||
return;
|
||||
}
|
||||
if (messages) {
|
||||
var summaryAttributes = [];
|
||||
for (var i in settings.attributes) {
|
||||
if (settings.attributes[i].summary) {
|
||||
summaryAttributes.push(settings.attributes[i].id);
|
||||
}
|
||||
}
|
||||
$.each(settings.attributes, function () {
|
||||
if ($.inArray(this.id, summaryAttributes) !== -1 && $.isArray(messages[this.id])) {
|
||||
$.each(messages[this.id], function (j, message) {
|
||||
content = content + '<li>' + message + '</li>';
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
$('#' + settings.summaryID).toggle(content !== '').find('ul').html(content);
|
||||
};
|
||||
|
||||
/**
|
||||
* Performs the ajax validation request.
|
||||
* This method is invoked internally to trigger the ajax validation.
|
||||
* @param form jquery the jquery representation of the form
|
||||
* @param successCallback function the function to be invoked if the ajax request succeeds
|
||||
* @param errorCallback function the function to be invoked if the ajax request fails
|
||||
*/
|
||||
$.fn.yiiactiveform.validate = function (form, successCallback, errorCallback) {
|
||||
var $form = $(form),
|
||||
settings = $form.data('settings'),
|
||||
needAjaxValidation = false,
|
||||
messages = {};
|
||||
$.each(settings.attributes, function () {
|
||||
var value,
|
||||
msg = [];
|
||||
if (this.clientValidation !== undefined && (settings.submitting || this.status === 2 || this.status === 3)) {
|
||||
value = getAFValue($form.find('#' + this.inputID));
|
||||
this.clientValidation(value, msg, this);
|
||||
if (msg.length) {
|
||||
messages[this.id] = msg;
|
||||
}
|
||||
}
|
||||
if (this.enableAjaxValidation && !msg.length && (settings.submitting || this.status === 2 || this.status === 3)) {
|
||||
needAjaxValidation = true;
|
||||
}
|
||||
});
|
||||
|
||||
if (!needAjaxValidation || settings.submitting && !$.isEmptyObject(messages)) {
|
||||
if (settings.submitting) {
|
||||
// delay callback so that the form can be submitted without problem
|
||||
setTimeout(function () {
|
||||
successCallback(messages);
|
||||
}, 200);
|
||||
} else {
|
||||
successCallback(messages);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
var $button = $form.data('submitObject'),
|
||||
extData = '&' + settings.ajaxVar + '=' + $form.attr('id');
|
||||
if ($button && $button.length) {
|
||||
extData += '&' + $button.attr('name') + '=' + $button.attr('value');
|
||||
}
|
||||
|
||||
$.ajax({
|
||||
url: settings.validationUrl,
|
||||
type: $form.attr('method'),
|
||||
data: $form.serialize() + extData,
|
||||
dataType: 'json',
|
||||
success: function (data) {
|
||||
if (data !== null && typeof data === 'object') {
|
||||
$.each(settings.attributes, function () {
|
||||
if (!this.enableAjaxValidation) {
|
||||
delete data[this.id];
|
||||
}
|
||||
});
|
||||
successCallback($.extend({}, messages, data));
|
||||
} else {
|
||||
successCallback(messages);
|
||||
}
|
||||
},
|
||||
error: function () {
|
||||
if (errorCallback !== undefined) {
|
||||
errorCallback();
|
||||
}
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* Returns the configuration for the specified form.
|
||||
* The configuration contains all needed information to perform ajax-based validation.
|
||||
* @param form jquery the jquery representation of the form
|
||||
* @return object the configuration for the specified form.
|
||||
*/
|
||||
$.fn.yiiactiveform.getSettings = function (form) {
|
||||
return $(form).data('settings');
|
||||
};
|
||||
|
||||
$.fn.yiiactiveform.defaults = {
|
||||
ajaxVar: 'ajax',
|
||||
validationUrl: undefined,
|
||||
validationDelay: 200,
|
||||
validateOnSubmit: false,
|
||||
validateOnChange: true,
|
||||
validateOnType: false,
|
||||
hideErrorMessage: false,
|
||||
inputContainer: undefined,
|
||||
errorCss: 'error',
|
||||
errorCssClass: 'error',
|
||||
successCssClass: 'success',
|
||||
validatingCssClass: 'validating',
|
||||
summaryID: undefined,
|
||||
timer: undefined,
|
||||
beforeValidateAttribute: undefined, // function (form, attribute) | boolean
|
||||
afterValidateAttribute: undefined, // function (form, attribute, data, hasError)
|
||||
beforeValidate: undefined, // function (form) | boolean
|
||||
afterValidate: undefined, // function (form, data, hasError) | boolean
|
||||
focus: undefined, // jquery selector that indicates which element to receive input focus initially
|
||||
/**
|
||||
* list of attributes to be validated. Each array element is of the following structure:
|
||||
* {
|
||||
* id: 'ModelClass_attribute', // the unique attribute ID
|
||||
* model: 'ModelClass', // the model class name
|
||||
* name: 'name', // attribute name
|
||||
* inputID: 'input-tag-id',
|
||||
* errorID: 'error-tag-id',
|
||||
* value: undefined,
|
||||
* status: 0, // 0: empty, not entered before, 1: validated, 2: pending validation, 3: validating
|
||||
* validationDelay: 200,
|
||||
* validateOnChange: true,
|
||||
* validateOnType: false,
|
||||
* hideErrorMessage: false,
|
||||
* inputContainer: undefined,
|
||||
* errorCssClass: 'error',
|
||||
* successCssClass: 'success',
|
||||
* validatingCssClass: 'validating',
|
||||
* enableAjaxValidation: true,
|
||||
* enableClientValidation: true,
|
||||
* clientValidation: undefined, // function (value, messages, attribute) | client-side validation
|
||||
* beforeValidateAttribute: undefined, // function (form, attribute) | boolean
|
||||
* afterValidateAttribute: undefined, // function (form, attribute, data, hasError)
|
||||
* }
|
||||
*/
|
||||
attributes: []
|
||||
};
|
||||
})(jQuery);
|
49
yii/assets/7b3570a4/jquery.yiitab.js
Normal file
@ -0,0 +1,49 @@
|
||||
/**
|
||||
* jQuery Yii plugin file.
|
||||
*
|
||||
* @author Qiang Xue <qiang.xue@gmail.com>
|
||||
* @link http://www.yiiframework.com/
|
||||
* @copyright 2008-2010 Yii Software LLC
|
||||
* @license http://www.yiiframework.com/license/
|
||||
*/
|
||||
|
||||
;(function($) {
|
||||
|
||||
$.extend($.fn, {
|
||||
yiitab: function() {
|
||||
|
||||
function activate(id) {
|
||||
var pos = id.indexOf("#");
|
||||
if (pos>=0) {
|
||||
id = id.substring(pos);
|
||||
}
|
||||
var $tab=$(id);
|
||||
var $container=$tab.parent();
|
||||
$container.find('>ul a').removeClass('active');
|
||||
$container.find('>ul a[href="'+id+'"]').addClass('active');
|
||||
$container.children('div').hide();
|
||||
$tab.show();
|
||||
}
|
||||
|
||||
this.find('>ul a').click(function(event) {
|
||||
var href=$(this).attr('href');
|
||||
var pos=href.indexOf('#');
|
||||
activate(href);
|
||||
if(pos==0 || (pos>0 && (window.location.pathname=='' || window.location.pathname==href.substring(0,pos))))
|
||||
return false;
|
||||
});
|
||||
|
||||
// activate a tab based on the current anchor
|
||||
var url = decodeURI(window.location);
|
||||
var pos = url.indexOf("#");
|
||||
if (pos >= 0) {
|
||||
var id = url.substring(pos);
|
||||
if (this.find('>ul a[href="'+id+'"]').length > 0) {
|
||||
activate(id);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
})(jQuery);
|
After Width: | Height: | Size: 86 B |
After Width: | Height: | Size: 75 B |
After Width: | Height: | Size: 144 B |
After Width: | Height: | Size: 99 B |
After Width: | Height: | Size: 142 B |
After Width: | Height: | Size: 137 B |
After Width: | Height: | Size: 140 B |
After Width: | Height: | Size: 86 B |
After Width: | Height: | Size: 3.7 KiB |
After Width: | Height: | Size: 3.7 KiB |
After Width: | Height: | Size: 3.7 KiB |
After Width: | Height: | Size: 3.7 KiB |
After Width: | Height: | Size: 3.7 KiB |
10
yii/assets/7b3570a4/jui/css/base/jquery-ui.css
vendored
Normal file
5
yii/assets/7b3570a4/jui/css/base/jquery.ui.accordion.css
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
/*! jQuery UI - v1.9.2 - 2012-11-23
|
||||
* http://jqueryui.com
|
||||
* Includes: jquery.ui.accordion.css
|
||||
* Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
|
||||
.ui-accordion .ui-accordion-header{display:block;cursor:pointer;position:relative;margin-top:2px;padding:.5em .5em .5em .7em;zoom:1}.ui-accordion .ui-accordion-icons{padding-left:2.2em}.ui-accordion .ui-accordion-noicons{padding-left:.7em}.ui-accordion .ui-accordion-icons .ui-accordion-icons{padding-left:2.2em}.ui-accordion .ui-accordion-header .ui-accordion-header-icon{position:absolute;left:.5em;top:50%;margin-top:-8px}.ui-accordion .ui-accordion-content{padding:1em 2.2em;border-top:0;overflow:auto;zoom:1}
|
5
yii/assets/7b3570a4/jui/css/base/jquery.ui.autocomplete.css
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
/*! jQuery UI - v1.9.2 - 2012-11-23
|
||||
* http://jqueryui.com
|
||||
* Includes: jquery.ui.autocomplete.css
|
||||
* Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
|
||||
.ui-autocomplete{position:absolute;top:0;left:0;cursor:default}* html .ui-autocomplete{width:1px}
|
5
yii/assets/7b3570a4/jui/css/base/jquery.ui.button.css
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
/*! jQuery UI - v1.9.2 - 2012-11-23
|
||||
* http://jqueryui.com
|
||||
* Includes: jquery.ui.button.css
|
||||
* Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
|
||||
.ui-button{display:inline-block;position:relative;padding:0;margin-right:.1em;cursor:pointer;text-align:center;zoom:1;overflow:visible}.ui-button,.ui-button:link,.ui-button:visited,.ui-button:hover,.ui-button:active{text-decoration:none}.ui-button-icon-only{width:2.2em}button.ui-button-icon-only{width:2.4em}.ui-button-icons-only{width:3.4em}button.ui-button-icons-only{width:3.7em}.ui-button .ui-button-text{display:block;line-height:1.4}.ui-button-text-only .ui-button-text{padding:.4em 1em}.ui-button-icon-only .ui-button-text,.ui-button-icons-only .ui-button-text{padding:.4em;text-indent:-9999999px}.ui-button-text-icon-primary .ui-button-text,.ui-button-text-icons .ui-button-text{padding:.4em 1em .4em 2.1em}.ui-button-text-icon-secondary .ui-button-text,.ui-button-text-icons .ui-button-text{padding:.4em 2.1em .4em 1em}.ui-button-text-icons .ui-button-text{padding-left:2.1em;padding-right:2.1em}input.ui-button{padding:.4em 1em}.ui-button-icon-only .ui-icon,.ui-button-text-icon-primary .ui-icon,.ui-button-text-icon-secondary .ui-icon,.ui-button-text-icons .ui-icon,.ui-button-icons-only .ui-icon{position:absolute;top:50%;margin-top:-8px}.ui-button-icon-only .ui-icon{left:50%;margin-left:-8px}.ui-button-text-icon-primary .ui-button-icon-primary,.ui-button-text-icons .ui-button-icon-primary,.ui-button-icons-only .ui-button-icon-primary{left:.5em}.ui-button-text-icon-secondary .ui-button-icon-secondary,.ui-button-text-icons .ui-button-icon-secondary,.ui-button-icons-only .ui-button-icon-secondary{right:.5em}.ui-button-text-icons .ui-button-icon-secondary,.ui-button-icons-only .ui-button-icon-secondary{right:.5em}.ui-buttonset{margin-right:7px}.ui-buttonset .ui-button{margin-left:0;margin-right:-.3em}button.ui-button::-moz-focus-inner{border:0;padding:0}
|
5
yii/assets/7b3570a4/jui/css/base/jquery.ui.core.css
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
/*! jQuery UI - v1.9.2 - 2012-11-23
|
||||
* http://jqueryui.com
|
||||
* Includes: jquery.ui.core.css
|
||||
* Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
|
||||
.ui-helper-hidden{display:none}.ui-helper-hidden-accessible{border:0;clip:rect(0 0 0 0);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px}.ui-helper-reset{margin:0;padding:0;border:0;outline:0;line-height:1.3;text-decoration:none;font-size:100%;list-style:none}.ui-helper-clearfix:before,.ui-helper-clearfix:after{content:"";display:table}.ui-helper-clearfix:after{clear:both}.ui-helper-clearfix{zoom:1}.ui-helper-zfix{width:100%;height:100%;top:0;left:0;position:absolute;opacity:0;filter:Alpha(Opacity=0)}.ui-state-disabled{cursor:default!important}.ui-icon{display:block;text-indent:-99999px;overflow:hidden;background-repeat:no-repeat}.ui-widget-overlay{position:absolute;top:0;left:0;width:100%;height:100%}
|
5
yii/assets/7b3570a4/jui/css/base/jquery.ui.datepicker.css
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
/*! jQuery UI - v1.9.2 - 2012-11-23
|
||||
* http://jqueryui.com
|
||||
* Includes: jquery.ui.datepicker.css
|
||||
* Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
|
||||
.ui-datepicker{width:17em;padding:.2em .2em 0;display:none}.ui-datepicker .ui-datepicker-header{position:relative;padding:.2em 0}.ui-datepicker .ui-datepicker-prev,.ui-datepicker .ui-datepicker-next{position:absolute;top:2px;width:1.8em;height:1.8em}.ui-datepicker .ui-datepicker-prev-hover,.ui-datepicker .ui-datepicker-next-hover{top:1px}.ui-datepicker .ui-datepicker-prev{left:2px}.ui-datepicker .ui-datepicker-next{right:2px}.ui-datepicker .ui-datepicker-prev-hover{left:1px}.ui-datepicker .ui-datepicker-next-hover{right:1px}.ui-datepicker .ui-datepicker-prev span,.ui-datepicker .ui-datepicker-next span{display:block;position:absolute;left:50%;margin-left:-8px;top:50%;margin-top:-8px}.ui-datepicker .ui-datepicker-title{margin:0 2.3em;line-height:1.8em;text-align:center}.ui-datepicker .ui-datepicker-title select{font-size:1em;margin:1px 0}.ui-datepicker select.ui-datepicker-month-year{width:100%}.ui-datepicker select.ui-datepicker-month,.ui-datepicker select.ui-datepicker-year{width:49%}.ui-datepicker table{width:100%;font-size:.9em;border-collapse:collapse;margin:0 0 .4em}.ui-datepicker th{padding:.7em .3em;text-align:center;font-weight:bold;border:0}.ui-datepicker td{border:0;padding:1px}.ui-datepicker td span,.ui-datepicker td a{display:block;padding:.2em;text-align:right;text-decoration:none}.ui-datepicker .ui-datepicker-buttonpane{background-image:none;margin:.7em 0 0 0;padding:0 .2em;border-left:0;border-right:0;border-bottom:0}.ui-datepicker .ui-datepicker-buttonpane button{float:right;margin:.5em .2em .4em;cursor:pointer;padding:.2em .6em .3em .6em;width:auto;overflow:visible}.ui-datepicker .ui-datepicker-buttonpane button.ui-datepicker-current{float:left}.ui-datepicker.ui-datepicker-multi{width:auto}.ui-datepicker-multi .ui-datepicker-group{float:left}.ui-datepicker-multi .ui-datepicker-group table{width:95%;margin:0 auto .4em}.ui-datepicker-multi-2 .ui-datepicker-group{width:50%}.ui-datepicker-multi-3 .ui-datepicker-group{width:33.3%}.ui-datepicker-multi-4 .ui-datepicker-group{width:25%}.ui-datepicker-multi .ui-datepicker-group-last .ui-datepicker-header{border-left-width:0}.ui-datepicker-multi .ui-datepicker-group-middle .ui-datepicker-header{border-left-width:0}.ui-datepicker-multi .ui-datepicker-buttonpane{clear:left}.ui-datepicker-row-break{clear:both;width:100%;font-size:0em}.ui-datepicker-rtl{direction:rtl}.ui-datepicker-rtl .ui-datepicker-prev{right:2px;left:auto}.ui-datepicker-rtl .ui-datepicker-next{left:2px;right:auto}.ui-datepicker-rtl .ui-datepicker-prev:hover{right:1px;left:auto}.ui-datepicker-rtl .ui-datepicker-next:hover{left:1px;right:auto}.ui-datepicker-rtl .ui-datepicker-buttonpane{clear:right}.ui-datepicker-rtl .ui-datepicker-buttonpane button{float:left}.ui-datepicker-rtl .ui-datepicker-buttonpane button.ui-datepicker-current{float:right}.ui-datepicker-rtl .ui-datepicker-group{float:right}.ui-datepicker-rtl .ui-datepicker-group-last .ui-datepicker-header{border-right-width:0;border-left-width:1px}.ui-datepicker-rtl .ui-datepicker-group-middle .ui-datepicker-header{border-right-width:0;border-left-width:1px}.ui-datepicker-cover{position:absolute;z-index:-1;filter:mask();top:-4px;left:-4px;width:200px;height:200px}
|
5
yii/assets/7b3570a4/jui/css/base/jquery.ui.dialog.css
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
/*! jQuery UI - v1.9.2 - 2012-11-23
|
||||
* http://jqueryui.com
|
||||
* Includes: jquery.ui.dialog.css
|
||||
* Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
|
||||
.ui-dialog{position:absolute;top:0;left:0;padding:.2em;width:300px;overflow:hidden}.ui-dialog .ui-dialog-titlebar{padding:.4em 1em;position:relative}.ui-dialog .ui-dialog-title{float:left;margin:.1em 16px .1em 0}.ui-dialog .ui-dialog-titlebar-close{position:absolute;right:.3em;top:50%;width:19px;margin:-10px 0 0 0;padding:1px;height:18px}.ui-dialog .ui-dialog-titlebar-close span{display:block;margin:1px}.ui-dialog .ui-dialog-titlebar-close:hover,.ui-dialog .ui-dialog-titlebar-close:focus{padding:0}.ui-dialog .ui-dialog-content{position:relative;border:0;padding:.5em 1em;background:none;overflow:auto;zoom:1}.ui-dialog .ui-dialog-buttonpane{text-align:left;border-width:1px 0 0 0;background-image:none;margin:.5em 0 0 0;padding:.3em 1em .5em .4em}.ui-dialog .ui-dialog-buttonpane .ui-dialog-buttonset{float:right}.ui-dialog .ui-dialog-buttonpane button{margin:.5em .4em .5em 0;cursor:pointer}.ui-dialog .ui-resizable-se{width:14px;height:14px;right:3px;bottom:3px}.ui-draggable .ui-dialog-titlebar{cursor:move}
|
5
yii/assets/7b3570a4/jui/css/base/jquery.ui.menu.css
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
/*! jQuery UI - v1.9.2 - 2012-11-23
|
||||
* http://jqueryui.com
|
||||
* Includes: jquery.ui.menu.css
|
||||
* Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
|
||||
.ui-menu{list-style:none;padding:2px;margin:0;display:block;outline:none}.ui-menu .ui-menu{margin-top:-3px;position:absolute}.ui-menu .ui-menu-item{margin:0;padding:0;zoom:1;width:100%}.ui-menu .ui-menu-divider{margin:5px -2px 5px -2px;height:0;font-size:0;line-height:0;border-width:1px 0 0 0}.ui-menu .ui-menu-item a{text-decoration:none;display:block;padding:2px .4em;line-height:1.5;zoom:1;font-weight:normal}.ui-menu .ui-menu-item a.ui-state-focus,.ui-menu .ui-menu-item a.ui-state-active{font-weight:normal;margin:-1px}.ui-menu .ui-state-disabled{font-weight:normal;margin:.4em 0 .2em;line-height:1.5}.ui-menu .ui-state-disabled a{cursor:default}.ui-menu-icons{position:relative}.ui-menu-icons .ui-menu-item a{position:relative;padding-left:2em}.ui-menu .ui-icon{position:absolute;top:.2em;left:.2em}.ui-menu .ui-menu-icon{position:static;float:right}
|
5
yii/assets/7b3570a4/jui/css/base/jquery.ui.progressbar.css
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
/*! jQuery UI - v1.9.2 - 2012-11-23
|
||||
* http://jqueryui.com
|
||||
* Includes: jquery.ui.progressbar.css
|
||||
* Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
|
||||
.ui-progressbar{height:2em;text-align:left;overflow:hidden}.ui-progressbar .ui-progressbar-value{margin:-1px;height:100%}
|
5
yii/assets/7b3570a4/jui/css/base/jquery.ui.resizable.css
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
/*! jQuery UI - v1.9.2 - 2012-11-23
|
||||
* http://jqueryui.com
|
||||
* Includes: jquery.ui.resizable.css
|
||||
* Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
|
||||
.ui-resizable{position:relative}.ui-resizable-handle{position:absolute;font-size:0.1px;display:block}.ui-resizable-disabled .ui-resizable-handle,.ui-resizable-autohide .ui-resizable-handle{display:none}.ui-resizable-n{cursor:n-resize;height:7px;width:100%;top:-5px;left:0}.ui-resizable-s{cursor:s-resize;height:7px;width:100%;bottom:-5px;left:0}.ui-resizable-e{cursor:e-resize;width:7px;right:-5px;top:0;height:100%}.ui-resizable-w{cursor:w-resize;width:7px;left:-5px;top:0;height:100%}.ui-resizable-se{cursor:se-resize;width:12px;height:12px;right:1px;bottom:1px}.ui-resizable-sw{cursor:sw-resize;width:9px;height:9px;left:-5px;bottom:-5px}.ui-resizable-nw{cursor:nw-resize;width:9px;height:9px;left:-5px;top:-5px}.ui-resizable-ne{cursor:ne-resize;width:9px;height:9px;right:-5px;top:-5px}
|
5
yii/assets/7b3570a4/jui/css/base/jquery.ui.selectable.css
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
/*! jQuery UI - v1.9.2 - 2012-11-23
|
||||
* http://jqueryui.com
|
||||
* Includes: jquery.ui.selectable.css
|
||||
* Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
|
||||
.ui-selectable-helper{position:absolute;z-index:100;border:1px dotted black}
|
5
yii/assets/7b3570a4/jui/css/base/jquery.ui.slider.css
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
/*! jQuery UI - v1.9.2 - 2012-11-23
|
||||
* http://jqueryui.com
|
||||
* Includes: jquery.ui.slider.css
|
||||
* Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
|
||||
.ui-slider{position:relative;text-align:left}.ui-slider .ui-slider-handle{position:absolute;z-index:2;width:1.2em;height:1.2em;cursor:default}.ui-slider .ui-slider-range{position:absolute;z-index:1;font-size:.7em;display:block;border:0;background-position:0 0}.ui-slider-horizontal{height:.8em}.ui-slider-horizontal .ui-slider-handle{top:-.3em;margin-left:-.6em}.ui-slider-horizontal .ui-slider-range{top:0;height:100%}.ui-slider-horizontal .ui-slider-range-min{left:0}.ui-slider-horizontal .ui-slider-range-max{right:0}.ui-slider-vertical{width:.8em;height:100px}.ui-slider-vertical .ui-slider-handle{left:-.3em;margin-left:0;margin-bottom:-.6em}.ui-slider-vertical .ui-slider-range{left:0;width:100%}.ui-slider-vertical .ui-slider-range-min{bottom:0}.ui-slider-vertical .ui-slider-range-max{top:0}
|
5
yii/assets/7b3570a4/jui/css/base/jquery.ui.spinner.css
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
/*! jQuery UI - v1.9.2 - 2012-11-23
|
||||
* http://jqueryui.com
|
||||
* Includes: jquery.ui.spinner.css
|
||||
* Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
|
||||
.ui-spinner{position:relative;display:inline-block;overflow:hidden;padding:0;vertical-align:middle}.ui-spinner-input{border:none;background:none;padding:0;margin:.2em 0;vertical-align:middle;margin-left:.4em;margin-right:22px}.ui-spinner-button{width:16px;height:50%;font-size:.5em;padding:0;margin:0;text-align:center;position:absolute;cursor:default;display:block;overflow:hidden;right:0}.ui-spinner a.ui-spinner-button{border-top:none;border-bottom:none;border-right:none}.ui-spinner .ui-icon{position:absolute;margin-top:-8px;top:50%;left:0}.ui-spinner-up{top:0}.ui-spinner-down{bottom:0}.ui-spinner .ui-icon-triangle-1-s{background-position:-65px -16px}
|
5
yii/assets/7b3570a4/jui/css/base/jquery.ui.tabs.css
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
/*! jQuery UI - v1.9.2 - 2012-11-23
|
||||
* http://jqueryui.com
|
||||
* Includes: jquery.ui.tabs.css
|
||||
* Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
|
||||
.ui-tabs{position:relative;padding:.2em;zoom:1}.ui-tabs .ui-tabs-nav{margin:0;padding:.2em .2em 0}.ui-tabs .ui-tabs-nav li{list-style:none;float:left;position:relative;top:0;margin:1px .2em 0 0;border-bottom:0;padding:0;white-space:nowrap}.ui-tabs .ui-tabs-nav li a{float:left;padding:.5em 1em;text-decoration:none}.ui-tabs .ui-tabs-nav li.ui-tabs-active{margin-bottom:-1px;padding-bottom:1px}.ui-tabs .ui-tabs-nav li.ui-tabs-active a,.ui-tabs .ui-tabs-nav li.ui-state-disabled a,.ui-tabs .ui-tabs-nav li.ui-tabs-loading a{cursor:text}.ui-tabs .ui-tabs-nav li a,.ui-tabs-collapsible .ui-tabs-nav li.ui-tabs-active a{cursor:pointer}.ui-tabs .ui-tabs-panel{display:block;border-width:0;padding:1em 1.4em;background:none}
|
5
yii/assets/7b3570a4/jui/css/base/jquery.ui.theme.css
vendored
Normal file
5
yii/assets/7b3570a4/jui/css/base/jquery.ui.tooltip.css
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
/*! jQuery UI - v1.9.2 - 2012-11-23
|
||||
* http://jqueryui.com
|
||||
* Includes: jquery.ui.tooltip.css
|
||||
* Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
|
||||
.ui-tooltip{padding:8px;position:absolute;z-index:9999;max-width:300px;-webkit-box-shadow:0 0 5px #aaa;box-shadow:0 0 5px #aaa}* html .ui-tooltip{background-image:none}body .ui-tooltip{border-width:2px}
|
5
yii/assets/7b3570a4/jui/js/jquery-ui-i18n.min.js
vendored
Normal file
6
yii/assets/7b3570a4/jui/js/jquery-ui.min.js
vendored
Normal file
510
yii/assets/7b3570a4/punycode.js
Normal file
@ -0,0 +1,510 @@
|
||||
/*! http://mths.be/punycode v1.2.0 by @mathias */
|
||||
;(function(root) {
|
||||
|
||||
/**
|
||||
* The `punycode` object.
|
||||
* @name punycode
|
||||
* @type Object
|
||||
*/
|
||||
var punycode,
|
||||
|
||||
/** Detect free variables `define`, `exports`, `module` and `require` */
|
||||
freeDefine = typeof define == 'function' && typeof define.amd == 'object' &&
|
||||
define.amd && define,
|
||||
freeExports = typeof exports == 'object' && exports,
|
||||
freeModule = typeof module == 'object' && module,
|
||||
freeRequire = typeof require == 'function' && require,
|
||||
|
||||
/** Highest positive signed 32-bit float value */
|
||||
maxInt = 2147483647, // aka. 0x7FFFFFFF or 2^31-1
|
||||
|
||||
/** Bootstring parameters */
|
||||
base = 36,
|
||||
tMin = 1,
|
||||
tMax = 26,
|
||||
skew = 38,
|
||||
damp = 700,
|
||||
initialBias = 72,
|
||||
initialN = 128, // 0x80
|
||||
delimiter = '-', // '\x2D'
|
||||
|
||||
/** Regular expressions */
|
||||
regexPunycode = /^xn--/,
|
||||
regexNonASCII = /[^ -~]/, // unprintable ASCII chars + non-ASCII chars
|
||||
regexSeparators = /\x2E|\u3002|\uFF0E|\uFF61/g, // RFC 3490 separators
|
||||
|
||||
/** Error messages */
|
||||
errors = {
|
||||
'overflow': 'Overflow: input needs wider integers to process',
|
||||
'not-basic': 'Illegal input >= 0x80 (not a basic code point)',
|
||||
'invalid-input': 'Invalid input'
|
||||
},
|
||||
|
||||
/** Convenience shortcuts */
|
||||
baseMinusTMin = base - tMin,
|
||||
floor = Math.floor,
|
||||
stringFromCharCode = String.fromCharCode,
|
||||
|
||||
/** Temporary variable */
|
||||
key;
|
||||
|
||||
/*--------------------------------------------------------------------------*/
|
||||
|
||||
/**
|
||||
* A generic error utility function.
|
||||
* @private
|
||||
* @param {String} type The error type.
|
||||
* @returns {Error} Throws a `RangeError` with the applicable error message.
|
||||
*/
|
||||
function error(type) {
|
||||
throw RangeError(errors[type]);
|
||||
}
|
||||
|
||||
/**
|
||||
* A generic `Array#map` utility function.
|
||||
* @private
|
||||
* @param {Array} array The array to iterate over.
|
||||
* @param {Function} callback The function that gets called for every array
|
||||
* item.
|
||||
* @returns {Array} A new array of values returned by the callback function.
|
||||
*/
|
||||
function map(array, fn) {
|
||||
var length = array.length;
|
||||
while (length--) {
|
||||
array[length] = fn(array[length]);
|
||||
}
|
||||
return array;
|
||||
}
|
||||
|
||||
/**
|
||||
* A simple `Array#map`-like wrapper to work with domain name strings.
|
||||
* @private
|
||||
* @param {String} domain The domain name.
|
||||
* @param {Function} callback The function that gets called for every
|
||||
* character.
|
||||
* @returns {Array} A new string of characters returned by the callback
|
||||
* function.
|
||||
*/
|
||||
function mapDomain(string, fn) {
|
||||
return map(string.split(regexSeparators), fn).join('.');
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates an array containing the decimal code points of each Unicode
|
||||
* character in the string. While JavaScript uses UCS-2 internally,
|
||||
* this function will convert a pair of surrogate halves (each of which
|
||||
* UCS-2 exposes as separate characters) into a single code point,
|
||||
* matching UTF-16.
|
||||
* @see `punycode.ucs2.encode`
|
||||
* @see <http://mathiasbynens.be/notes/javascript-encoding>
|
||||
* @memberOf punycode.ucs2
|
||||
* @name decode
|
||||
* @param {String} string The Unicode input string (UCS-2).
|
||||
* @returns {Array} The new array of code points.
|
||||
*/
|
||||
function ucs2decode(string) {
|
||||
var output = [],
|
||||
counter = 0,
|
||||
length = string.length,
|
||||
value,
|
||||
extra;
|
||||
while (counter < length) {
|
||||
value = string.charCodeAt(counter++);
|
||||
if ((value & 0xF800) == 0xD800 && counter < length) {
|
||||
// high surrogate, and there is a next character
|
||||
extra = string.charCodeAt(counter++);
|
||||
if ((extra & 0xFC00) == 0xDC00) { // low surrogate
|
||||
output.push(((value & 0x3FF) << 10) + (extra & 0x3FF) + 0x10000);
|
||||
} else {
|
||||
output.push(value, extra);
|
||||
}
|
||||
} else {
|
||||
output.push(value);
|
||||
}
|
||||
}
|
||||
return output;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a string based on an array of decimal code points.
|
||||
* @see `punycode.ucs2.decode`
|
||||
* @memberOf punycode.ucs2
|
||||
* @name encode
|
||||
* @param {Array} codePoints The array of decimal code points.
|
||||
* @returns {String} The new Unicode string (UCS-2).
|
||||
*/
|
||||
function ucs2encode(array) {
|
||||
return map(array, function(value) {
|
||||
var output = '';
|
||||
if (value > 0xFFFF) {
|
||||
value -= 0x10000;
|
||||
output += stringFromCharCode(value >>> 10 & 0x3FF | 0xD800);
|
||||
value = 0xDC00 | value & 0x3FF;
|
||||
}
|
||||
output += stringFromCharCode(value);
|
||||
return output;
|
||||
}).join('');
|
||||
}
|
||||
|
||||
/**
|
||||
* Converts a basic code point into a digit/integer.
|
||||
* @see `digitToBasic()`
|
||||
* @private
|
||||
* @param {Number} codePoint The basic (decimal) code point.
|
||||
* @returns {Number} The numeric value of a basic code point (for use in
|
||||
* representing integers) in the range `0` to `base - 1`, or `base` if
|
||||
* the code point does not represent a value.
|
||||
*/
|
||||
function basicToDigit(codePoint) {
|
||||
return codePoint - 48 < 10
|
||||
? codePoint - 22
|
||||
: codePoint - 65 < 26
|
||||
? codePoint - 65
|
||||
: codePoint - 97 < 26
|
||||
? codePoint - 97
|
||||
: base;
|
||||
}
|
||||
|
||||
/**
|
||||
* Converts a digit/integer into a basic code point.
|
||||
* @see `basicToDigit()`
|
||||
* @private
|
||||
* @param {Number} digit The numeric value of a basic code point.
|
||||
* @returns {Number} The basic code point whose value (when used for
|
||||
* representing integers) is `digit`, which needs to be in the range
|
||||
* `0` to `base - 1`. If `flag` is non-zero, the uppercase form is
|
||||
* used; else, the lowercase form is used. The behavior is undefined
|
||||
* if flag is non-zero and `digit` has no uppercase form.
|
||||
*/
|
||||
function digitToBasic(digit, flag) {
|
||||
// 0..25 map to ASCII a..z or A..Z
|
||||
// 26..35 map to ASCII 0..9
|
||||
return digit + 22 + 75 * (digit < 26) - ((flag != 0) << 5);
|
||||
}
|
||||
|
||||
/**
|
||||
* Bias adaptation function as per section 3.4 of RFC 3492.
|
||||
* http://tools.ietf.org/html/rfc3492#section-3.4
|
||||
* @private
|
||||
*/
|
||||
function adapt(delta, numPoints, firstTime) {
|
||||
var k = 0;
|
||||
delta = firstTime ? floor(delta / damp) : delta >> 1;
|
||||
delta += floor(delta / numPoints);
|
||||
for (/* no initialization */; delta > baseMinusTMin * tMax >> 1; k += base) {
|
||||
delta = floor(delta / baseMinusTMin);
|
||||
}
|
||||
return floor(k + (baseMinusTMin + 1) * delta / (delta + skew));
|
||||
}
|
||||
|
||||
/**
|
||||
* Converts a basic code point to lowercase if `flag` is falsy, or to
|
||||
* uppercase if `flag` is truthy. The code point is unchanged if it's
|
||||
* caseless. The behavior is undefined if `codePoint` is not a basic code
|
||||
* point.
|
||||
* @private
|
||||
* @param {Number} codePoint The numeric value of a basic code point.
|
||||
* @returns {Number} The resulting basic code point.
|
||||
*/
|
||||
function encodeBasic(codePoint, flag) {
|
||||
codePoint -= (codePoint - 97 < 26) << 5;
|
||||
return codePoint + (!flag && codePoint - 65 < 26) << 5;
|
||||
}
|
||||
|
||||
/**
|
||||
* Converts a Punycode string of ASCII code points to a string of Unicode
|
||||
* code points.
|
||||
* @memberOf punycode
|
||||
* @param {String} input The Punycode string of ASCII code points.
|
||||
* @returns {String} The resulting string of Unicode code points.
|
||||
*/
|
||||
function decode(input) {
|
||||
// Don't use UCS-2
|
||||
var output = [],
|
||||
inputLength = input.length,
|
||||
out,
|
||||
i = 0,
|
||||
n = initialN,
|
||||
bias = initialBias,
|
||||
basic,
|
||||
j,
|
||||
index,
|
||||
oldi,
|
||||
w,
|
||||
k,
|
||||
digit,
|
||||
t,
|
||||
length,
|
||||
/** Cached calculation results */
|
||||
baseMinusT;
|
||||
|
||||
// Handle the basic code points: let `basic` be the number of input code
|
||||
// points before the last delimiter, or `0` if there is none, then copy
|
||||
// the first basic code points to the output.
|
||||
|
||||
basic = input.lastIndexOf(delimiter);
|
||||
if (basic < 0) {
|
||||
basic = 0;
|
||||
}
|
||||
|
||||
for (j = 0; j < basic; ++j) {
|
||||
// if it's not a basic code point
|
||||
if (input.charCodeAt(j) >= 0x80) {
|
||||
error('not-basic');
|
||||
}
|
||||
output.push(input.charCodeAt(j));
|
||||
}
|
||||
|
||||
// Main decoding loop: start just after the last delimiter if any basic code
|
||||
// points were copied; start at the beginning otherwise.
|
||||
|
||||
for (index = basic > 0 ? basic + 1 : 0; index < inputLength; /* no final expression */) {
|
||||
|
||||
// `index` is the index of the next character to be consumed.
|
||||
// Decode a generalized variable-length integer into `delta`,
|
||||
// which gets added to `i`. The overflow checking is easier
|
||||
// if we increase `i` as we go, then subtract off its starting
|
||||
// value at the end to obtain `delta`.
|
||||
for (oldi = i, w = 1, k = base; /* no condition */; k += base) {
|
||||
|
||||
if (index >= inputLength) {
|
||||
error('invalid-input');
|
||||
}
|
||||
|
||||
digit = basicToDigit(input.charCodeAt(index++));
|
||||
|
||||
if (digit >= base || digit > floor((maxInt - i) / w)) {
|
||||
error('overflow');
|
||||
}
|
||||
|
||||
i += digit * w;
|
||||
t = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);
|
||||
|
||||
if (digit < t) {
|
||||
break;
|
||||
}
|
||||
|
||||
baseMinusT = base - t;
|
||||
if (w > floor(maxInt / baseMinusT)) {
|
||||
error('overflow');
|
||||
}
|
||||
|
||||
w *= baseMinusT;
|
||||
|
||||
}
|
||||
|
||||
out = output.length + 1;
|
||||
bias = adapt(i - oldi, out, oldi == 0);
|
||||
|
||||
// `i` was supposed to wrap around from `out` to `0`,
|
||||
// incrementing `n` each time, so we'll fix that now:
|
||||
if (floor(i / out) > maxInt - n) {
|
||||
error('overflow');
|
||||
}
|
||||
|
||||
n += floor(i / out);
|
||||
i %= out;
|
||||
|
||||
// Insert `n` at position `i` of the output
|
||||
output.splice(i++, 0, n);
|
||||
|
||||
}
|
||||
|
||||
return ucs2encode(output);
|
||||
}
|
||||
|
||||
/**
|
||||
* Converts a string of Unicode code points to a Punycode string of ASCII
|
||||
* code points.
|
||||
* @memberOf punycode
|
||||
* @param {String} input The string of Unicode code points.
|
||||
* @returns {String} The resulting Punycode string of ASCII code points.
|
||||
*/
|
||||
function encode(input) {
|
||||
var n,
|
||||
delta,
|
||||
handledCPCount,
|
||||
basicLength,
|
||||
bias,
|
||||
j,
|
||||
m,
|
||||
q,
|
||||
k,
|
||||
t,
|
||||
currentValue,
|
||||
output = [],
|
||||
/** `inputLength` will hold the number of code points in `input`. */
|
||||
inputLength,
|
||||
/** Cached calculation results */
|
||||
handledCPCountPlusOne,
|
||||
baseMinusT,
|
||||
qMinusT;
|
||||
|
||||
// Convert the input in UCS-2 to Unicode
|
||||
input = ucs2decode(input);
|
||||
|
||||
// Cache the length
|
||||
inputLength = input.length;
|
||||
|
||||
// Initialize the state
|
||||
n = initialN;
|
||||
delta = 0;
|
||||
bias = initialBias;
|
||||
|
||||
// Handle the basic code points
|
||||
for (j = 0; j < inputLength; ++j) {
|
||||
currentValue = input[j];
|
||||
if (currentValue < 0x80) {
|
||||
output.push(stringFromCharCode(currentValue));
|
||||
}
|
||||
}
|
||||
|
||||
handledCPCount = basicLength = output.length;
|
||||
|
||||
// `handledCPCount` is the number of code points that have been handled;
|
||||
// `basicLength` is the number of basic code points.
|
||||
|
||||
// Finish the basic string - if it is not empty - with a delimiter
|
||||
if (basicLength) {
|
||||
output.push(delimiter);
|
||||
}
|
||||
|
||||
// Main encoding loop:
|
||||
while (handledCPCount < inputLength) {
|
||||
|
||||
// All non-basic code points < n have been handled already. Find the next
|
||||
// larger one:
|
||||
for (m = maxInt, j = 0; j < inputLength; ++j) {
|
||||
currentValue = input[j];
|
||||
if (currentValue >= n && currentValue < m) {
|
||||
m = currentValue;
|
||||
}
|
||||
}
|
||||
|
||||
// Increase `delta` enough to advance the decoder's <n,i> state to <m,0>,
|
||||
// but guard against overflow
|
||||
handledCPCountPlusOne = handledCPCount + 1;
|
||||
if (m - n > floor((maxInt - delta) / handledCPCountPlusOne)) {
|
||||
error('overflow');
|
||||
}
|
||||
|
||||
delta += (m - n) * handledCPCountPlusOne;
|
||||
n = m;
|
||||
|
||||
for (j = 0; j < inputLength; ++j) {
|
||||
currentValue = input[j];
|
||||
|
||||
if (currentValue < n && ++delta > maxInt) {
|
||||
error('overflow');
|
||||
}
|
||||
|
||||
if (currentValue == n) {
|
||||
// Represent delta as a generalized variable-length integer
|
||||
for (q = delta, k = base; /* no condition */; k += base) {
|
||||
t = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);
|
||||
if (q < t) {
|
||||
break;
|
||||
}
|
||||
qMinusT = q - t;
|
||||
baseMinusT = base - t;
|
||||
output.push(
|
||||
stringFromCharCode(digitToBasic(t + qMinusT % baseMinusT, 0))
|
||||
);
|
||||
q = floor(qMinusT / baseMinusT);
|
||||
}
|
||||
|
||||
output.push(stringFromCharCode(digitToBasic(q, 0)));
|
||||
bias = adapt(delta, handledCPCountPlusOne, handledCPCount == basicLength);
|
||||
delta = 0;
|
||||
++handledCPCount;
|
||||
}
|
||||
}
|
||||
|
||||
++delta;
|
||||
++n;
|
||||
|
||||
}
|
||||
return output.join('');
|
||||
}
|
||||
|
||||
/**
|
||||
* Converts a Punycode string representing a domain name to Unicode. Only the
|
||||
* Punycoded parts of the domain name will be converted, i.e. it doesn't
|
||||
* matter if you call it on a string that has already been converted to
|
||||
* Unicode.
|
||||
* @memberOf punycode
|
||||
* @param {String} domain The Punycode domain name to convert to Unicode.
|
||||
* @returns {String} The Unicode representation of the given Punycode
|
||||
* string.
|
||||
*/
|
||||
function toUnicode(domain) {
|
||||
return mapDomain(domain, function(string) {
|
||||
return regexPunycode.test(string)
|
||||
? decode(string.slice(4).toLowerCase())
|
||||
: string;
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Converts a Unicode string representing a domain name to Punycode. Only the
|
||||
* non-ASCII parts of the domain name will be converted, i.e. it doesn't
|
||||
* matter if you call it with a domain that's already in ASCII.
|
||||
* @memberOf punycode
|
||||
* @param {String} domain The domain name to convert, as a Unicode string.
|
||||
* @returns {String} The Punycode representation of the given domain name.
|
||||
*/
|
||||
function toASCII(domain) {
|
||||
return mapDomain(domain, function(string) {
|
||||
return regexNonASCII.test(string)
|
||||
? 'xn--' + encode(string)
|
||||
: string;
|
||||
});
|
||||
}
|
||||
|
||||
/*--------------------------------------------------------------------------*/
|
||||
|
||||
/** Define the public API */
|
||||
punycode = {
|
||||
/**
|
||||
* A string representing the current Punycode.js version number.
|
||||
* @memberOf punycode
|
||||
* @type String
|
||||
*/
|
||||
'version': '1.2.0',
|
||||
/**
|
||||
* An object of methods to convert from JavaScript's internal character
|
||||
* representation (UCS-2) to decimal Unicode code points, and back.
|
||||
* @see <http://mathiasbynens.be/notes/javascript-encoding>
|
||||
* @memberOf punycode
|
||||
* @type Object
|
||||
*/
|
||||
'ucs2': {
|
||||
'decode': ucs2decode,
|
||||
'encode': ucs2encode
|
||||
},
|
||||
'decode': decode,
|
||||
'encode': encode,
|
||||
'toASCII': toASCII,
|
||||
'toUnicode': toUnicode
|
||||
};
|
||||
|
||||
/** Expose `punycode` */
|
||||
if (freeExports) {
|
||||
if (freeModule && freeModule.exports == freeExports) {
|
||||
// in Node.js or Ringo 0.8+
|
||||
freeModule.exports = punycode;
|
||||
} else {
|
||||
// in Narwhal or Ringo 0.7-
|
||||
for (key in punycode) {
|
||||
punycode.hasOwnProperty(key) && (freeExports[key] = punycode[key]);
|
||||
}
|
||||
}
|
||||
} else if (freeDefine) {
|
||||
// via curl.js or RequireJS
|
||||
define('punycode', punycode);
|
||||
} else {
|
||||
// in a browser or Rhino
|
||||
root.punycode = punycode;
|
||||
}
|
||||
|
||||
}(this));
|
2
yii/assets/7b3570a4/punycode.min.js
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
/*! http://mths.be/punycode v1.2.0 by @mathias */
|
||||
;(function(u){var I,e=typeof define=='function'&&typeof define.amd=='object'&&define.amd&&define,J=typeof exports=='object'&&exports,q=typeof module=='object'&&module,h=typeof require=='function'&&require,o=2147483647,p=36,i=1,H=26,B=38,b=700,m=72,G=128,C='-',E=/^xn--/,t=/[^ -~]/,l=/\x2E|\u3002|\uFF0E|\uFF61/g,s={overflow:'Overflow: input needs wider integers to process','not-basic':'Illegal input >= 0x80 (not a basic code point)','invalid-input':'Invalid input'},v=p-i,g=Math.floor,j=String.fromCharCode,n;function y(K){throw RangeError(s[K])}function z(M,K){var L=M.length;while(L--){M[L]=K(M[L])}return M}function f(K,L){return z(K.split(l),L).join('.')}function D(N){var M=[],L=0,O=N.length,P,K;while(L<O){P=N.charCodeAt(L++);if((P&63488)==55296&&L<O){K=N.charCodeAt(L++);if((K&64512)==56320){M.push(((P&1023)<<10)+(K&1023)+65536)}else{M.push(P,K)}}else{M.push(P)}}return M}function F(K){return z(K,function(M){var L='';if(M>65535){M-=65536;L+=j(M>>>10&1023|55296);M=56320|M&1023}L+=j(M);return L}).join('')}function c(K){return K-48<10?K-22:K-65<26?K-65:K-97<26?K-97:p}function A(L,K){return L+22+75*(L<26)-((K!=0)<<5)}function w(N,L,M){var K=0;N=M?g(N/b):N>>1;N+=g(N/L);for(;N>v*H>>1;K+=p){N=g(N/v)}return g(K+(v+1)*N/(N+B))}function k(L,K){L-=(L-97<26)<<5;return L+(!K&&L-65<26)<<5}function a(X){var N=[],Q=X.length,S,T=0,M=G,U=m,P,R,V,L,Y,O,W,aa,K,Z;P=X.lastIndexOf(C);if(P<0){P=0}for(R=0;R<P;++R){if(X.charCodeAt(R)>=128){y('not-basic')}N.push(X.charCodeAt(R))}for(V=P>0?P+1:0;V<Q;){for(L=T,Y=1,O=p;;O+=p){if(V>=Q){y('invalid-input')}W=c(X.charCodeAt(V++));if(W>=p||W>g((o-T)/Y)){y('overflow')}T+=W*Y;aa=O<=U?i:(O>=U+H?H:O-U);if(W<aa){break}Z=p-aa;if(Y>g(o/Z)){y('overflow')}Y*=Z}S=N.length+1;U=w(T-L,S,L==0);if(g(T/S)>o-M){y('overflow')}M+=g(T/S);T%=S;N.splice(T++,0,M)}return F(N)}function d(W){var N,Y,T,L,U,S,O,K,R,aa,X,M=[],Q,P,Z,V;W=D(W);Q=W.length;N=G;Y=0;U=m;for(S=0;S<Q;++S){X=W[S];if(X<128){M.push(j(X))}}T=L=M.length;if(L){M.push(C)}while(T<Q){for(O=o,S=0;S<Q;++S){X=W[S];if(X>=N&&X<O){O=X}}P=T+1;if(O-N>g((o-Y)/P)){y('overflow')}Y+=(O-N)*P;N=O;for(S=0;S<Q;++S){X=W[S];if(X<N&&++Y>o){y('overflow')}if(X==N){for(K=Y,R=p;;R+=p){aa=R<=U?i:(R>=U+H?H:R-U);if(K<aa){break}V=K-aa;Z=p-aa;M.push(j(A(aa+V%Z,0)));K=g(V/Z)}M.push(j(A(K,0)));U=w(Y,P,T==L);Y=0;++T}}++Y;++N}return M.join('')}function r(K){return f(K,function(L){return E.test(L)?a(L.slice(4).toLowerCase()):L})}function x(K){return f(K,function(L){return t.test(L)?'xn--'+d(L):L})}I={version:'1.2.0',ucs2:{decode:D,encode:F},decode:a,encode:d,toASCII:x,toUnicode:r};if(J){if(q&&q.exports==J){q.exports=I}else{for(n in I){I.hasOwnProperty(n)&&(J[n]=I[n])}}}else{if(e){define('punycode',I)}else{u.punycode=I}}}(this));
|
BIN
yii/assets/7b3570a4/rating/delete.gif
Normal file
After Width: | Height: | Size: 752 B |
12
yii/assets/7b3570a4/rating/jquery.rating.css
Normal file
@ -0,0 +1,12 @@
|
||||
/* jQuery.Rating Plugin CSS - http://www.fyneworks.com/jquery/star-rating/ */
|
||||
div.rating-cancel,div.star-rating{float:left;width:17px;height:15px;text-indent:-999em;cursor:pointer;display:block;background:transparent;overflow:hidden}
|
||||
div.rating-cancel,div.rating-cancel a{background:url(delete.gif) no-repeat 0 -16px}
|
||||
div.star-rating,div.star-rating a{background:url(star.gif) no-repeat 0 0px}
|
||||
div.rating-cancel a,div.star-rating a{display:block;width:16px;height:100%;background-position:0 0px;border:0}
|
||||
div.star-rating-on a{background-position:0 -16px!important}
|
||||
div.star-rating-hover a{background-position:0 -32px}
|
||||
/* Read Only CSS */
|
||||
div.star-rating-readonly a{cursor:default !important}
|
||||
/* Partial Star CSS */
|
||||
div.star-rating{background:transparent!important;overflow:hidden!important}
|
||||
/* END jQuery.Rating Plugin CSS */
|
BIN
yii/assets/7b3570a4/rating/star.gif
Normal file
After Width: | Height: | Size: 815 B |
BIN
yii/assets/7b3570a4/treeview/images/ajax-loader.gif
Normal file
After Width: | Height: | Size: 847 B |
BIN
yii/assets/7b3570a4/treeview/images/file.gif
Normal file
After Width: | Height: | Size: 110 B |
BIN
yii/assets/7b3570a4/treeview/images/folder-closed.gif
Normal file
After Width: | Height: | Size: 105 B |
BIN
yii/assets/7b3570a4/treeview/images/folder.gif
Normal file
After Width: | Height: | Size: 106 B |
BIN
yii/assets/7b3570a4/treeview/images/minus.gif
Normal file
After Width: | Height: | Size: 837 B |
BIN
yii/assets/7b3570a4/treeview/images/plus.gif
Normal file
After Width: | Height: | Size: 841 B |
BIN
yii/assets/7b3570a4/treeview/images/treeview-black-line.gif
Normal file
After Width: | Height: | Size: 1.8 KiB |
BIN
yii/assets/7b3570a4/treeview/images/treeview-black.gif
Normal file
After Width: | Height: | Size: 1.2 KiB |
BIN
yii/assets/7b3570a4/treeview/images/treeview-default-line.gif
Normal file
After Width: | Height: | Size: 1.9 KiB |
BIN
yii/assets/7b3570a4/treeview/images/treeview-default.gif
Normal file
After Width: | Height: | Size: 1.2 KiB |
BIN
yii/assets/7b3570a4/treeview/images/treeview-famfamfam-line.gif
Normal file
After Width: | Height: | Size: 807 B |
BIN
yii/assets/7b3570a4/treeview/images/treeview-famfamfam.gif
Normal file
After Width: | Height: | Size: 1.3 KiB |