diff --git a/module/my/view/task.html.php b/module/my/view/task.html.php index 652e76374a..382f9b725b 100644 --- a/module/my/view/task.html.php +++ b/module/my/view/task.html.php @@ -67,8 +67,8 @@ pri;?>'>task->priList, $task->pri);?> createLink('project', 'browse', "projectid=$task->projectID"), $task->projectName);?> - team)) echo '' . $this->lang->task->multipleAB . ' ';?> - parent)) echo '' . $this->lang->task->childrenAB . ' ';?> + team)) echo '' . $this->lang->task->multipleAB . ' ';?> + parent)) echo '' . $this->lang->task->childrenAB . ' ';?> createLink('task', 'view', "taskID=$task->id"), $task->name, null, "style='color: $task->color'");?> openedBy);?> diff --git a/module/project/css/common.css b/module/project/css/common.css index 472a5bf6d1..0a25a0bdd8 100644 --- a/module/project/css/common.css +++ b/module/project/css/common.css @@ -5,13 +5,13 @@ #productsBox .has-branch select {width: 100%; display: table-cell; border-radius: 0 2px 2px 0; border-left: none;} #productsBox .has-branch select:focus {box-shadow: inset 1px 0 #4d90fe} -.table-children > td:first-child{border-left:2px solid #ccc;} -.table-children > td:last-child{border-right:2px solid #ccc;} -.fixed-left .table-children > td{border-right:none;} -.flexarea .table-children > td{border-left:none;border-right:none;} -.fixed-right .table-children > td{border-left:none;} -.table-children.table-child-top{border-top:2px solid #ccc;} -.table-children.table-child-bottom{border-bottom:2px solid #ccc;} -.table-striped>tbody>tr.table-children:nth-child(odd)>td, .table-striped>tbody>tr.table-children:nth-child(odd)>th{background-color:#fff;} +.table-children {border-left: 2px solid #cbd0db; border-right: 2px solid #cbd0db;} +.table-children.table-child-top {border-top: 2px solid #cbd0db;} +.table-children.table-child-bottom {border-bottom: 2px solid #cbd0db;} +.table td.has-child > .task-toggle {color: #838a9d; position: relative; top: -1px;} +.table td.has-child > .task-toggle:hover {color: #006af1; cursor: pointer;} +.table td.has-child > .task-toggle > .icon {font-size: 16px; display: inline-block; transition: transform .2s;} +.table td.has-child > .task-toggle > .icon:before {text-align: left;} +.table td.has-child > .task-toggle.collapsed > .icon {transform: rotate(-90deg);} .chosen-container-single .chosen-single > span{max-width:200px;} diff --git a/module/project/css/task.css b/module/project/css/task.css index 2f40bcc11f..e69de29bb2 100644 --- a/module/project/css/task.css +++ b/module/project/css/task.css @@ -1,29 +0,0 @@ -.red{color:red;} - -.bug, .task {color:gray; font-size:9px} -.cont-lt1 .side{width:220px} -#hideButton{cursor:pointer;} -#hideButton span{padding:2px 10px; background:url(theme/default/images/main/zt-icons.png) -100px -161px;} -#featurebar .f-right .icon-green-task-import {padding:2px 8px; background:url(theme/default/images/main/zt-icons.png) 0px -82px;} -.sub-featurebar #querybox {margin:0px;} -.sub-featurebar #bysearchTab.active {padding:0px;} -.sub-featurebar #bysearchTab.active:hover {background:#fff;} - -#createActionMenu .dropdown-menu {width:100%;} - -.dropdown-menu.with-search {padding: 0; min-width: 150px; overflow: hidden; max-height: 302px;} -.dropdown-menu > .menu-search .input-group {width:100%;} -.dropdown-menu > .menu-search .input-group-addon {position: absolute; right: 10px; top: 0; z-index: 10; background: none; border: none; color: #666} -.dropdown-menu > .menu-search .form-control {border: none!important; box-shadow: none!important; border-top: 1px solid #ddd!important;} -.dropdown-list {display: block; padding: 0; max-height: 270px; overflow-y: auto;} -.dropdown-list > li > a {display: block; padding: 3px 20px; clear: both; font-weight: normal; line-height: 1.53846154; color: #141414; white-space: nowrap;} -.dropdown-list > li > a:hover, -.dropdown-list > li > a:focus {color: #1a4f85;text-decoration: none;background-color: #ddd;} - -.pl-5px{padding-left:5px;} - -tbody > tr > td > .btn-icon {margin-right: 2px} -#projectTaskForm{padding:0px 1px;} - -.table td.has-child > a {max-width: 90%; max-width: calc(100% - 30px); display: inline-block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;} -.table td.has-child > .task-toggle {position: relative; top: 1px} diff --git a/module/project/js/common.js b/module/project/js/common.js index 8c190e1f15..0d8b3abd47 100644 --- a/module/project/js/common.js +++ b/module/project/js/common.js @@ -220,15 +220,15 @@ function loadBranch(){} /* Auto compute the work days. */ $(function() { - if(typeof(replaceID) != 'undefined') - { - setModal4List('iframe', replaceID, function($list) - { - $list.find('.progress-pie:visible').progressPie(); - var datatable = $list.data('zui.datatable'); - if(datatable) datatable.$datatable.find('.progress-pie:visible').progressPie(); - }); - } + // if(typeof(replaceID) != 'undefined') + // { + // setModal4List('iframe', replaceID, function($list) + // { + // $list.find('.progress-pie:visible').progressPie(); + // var datatable = $list.data('zui.datatable'); + // if(datatable) datatable.$datatable.find('.progress-pie:visible').progressPie(); + // }); + // } $(".date").bind('dateSelected', function() { computeWorkDays(this.id); @@ -239,19 +239,10 @@ $(function() { $(document).on('click', '.task-toggle', function(e) { - var $toggleIcon = $(this).find('i'); - var id = $(this).data('id'); - - if($toggleIcon.hasClass('icon-double-angle-down')) - { - $('tr.parent-'+id).show(); - $toggleIcon.removeClass('icon-double-angle-down').addClass('icon-double-angle-up'); - } - else if($toggleIcon.hasClass('icon-double-angle-up')) - { - $('tr.parent-'+id).hide(); - $toggleIcon.removeClass('icon-double-angle-up').addClass('icon-double-angle-down'); - } + var $toggle = $(this); + var id = $(this).data('id'); + var isCollapsed = $toggle.toggleClass('collapsed').hasClass('collapsed'); + $toggle.closest('tbody').find('tr.parent-' + id).toggle(!isCollapsed); e.stopPropagation(); e.preventDefault(); diff --git a/module/project/view/task.html.php b/module/project/view/task.html.php index f646245249..6c68c12a51 100644 --- a/module/project/view/task.html.php +++ b/module/project/view/task.html.php @@ -185,7 +185,7 @@ js::set('browseType', $browseType); children as $key => $child):?> children)) ? ' table-child-bottom' : '';?> - + task->printCell($field, $child, $users, $browseType, $branchGroups, $modulePairs, $useDatatable ? 'datatable' : 'table', true);?> diff --git a/module/task/model.php b/module/task/model.php index b7a5de0b43..2b09fe0da1 100644 --- a/module/task/model.php +++ b/module/task/model.php @@ -2243,8 +2243,7 @@ class taskModel extends model if($id == 'deadline' and isset($task->delay)) $class .= ' delayed'; if($id == 'assignedTo') { - $class .= ' c-actions text-left'; - if($task->assignedTo == $account) $class .= ' red'; + $class .= ' has-btn text-left'; } $title = ''; @@ -2274,20 +2273,20 @@ class taskModel extends model echo ""; break; case 'name': + if(!empty($task->children)) echo ''; if(!empty($task->product) && isset($branchGroups[$task->product][$task->branch])) echo "" . $branchGroups[$task->product][$task->branch] . ' '; if(empty($task->children) and $task->module and isset($modulePairs[$task->module])) echo "" . $modulePairs[$task->module] . ' '; - if($child or !empty($task->parent)) echo '' . $this->lang->task->childrenAB . ' '; - if(!empty($task->team)) echo '' . $this->lang->task->multipleAB . ' '; + if($child or !empty($task->parent)) echo '' . $this->lang->task->childrenAB . ' '; + if(!empty($task->team)) echo '' . $this->lang->task->multipleAB . ' '; echo $canView ? html::a($taskLink, $task->name, null, "style='color: $task->color'") : "$task->name"; if($task->fromBug) echo html::a(helper::createLink('bug', 'view', "id=$task->fromBug"), "[BUG#$task->fromBug]", '_blank', "class='bug'"); - if(!empty($task->children)) echo '    '; break; case 'type': echo $this->lang->task->typeList[$task->type]; break; case 'status': $storyChanged = (!empty($task->storyStatus) and $task->storyStatus == 'active' and $task->latestStoryVersion > $task->storyVersion); - $storyChanged ? print("{$this->lang->story->changed} ") : print($this->lang->task->statusList[$task->status]); + $storyChanged ? print(" {$this->lang->story->changed}") : print(" {$this->lang->task->statusList[$task->status]}"); break; case 'estimate': echo round($task->estimate, 1); @@ -2317,8 +2316,17 @@ class taskModel extends model echo $task->realStarted; break; case 'assignedTo': - common::printIcon('task', 'assignTo', "projectID=$task->project&taskID=$task->id", $task, 'list', '', '', 'iframe', true); - echo zget($users, $task->assignedTo); + $btnTextClass = ''; + $assignedToText = $task->assignedTo; + if (empty($assignedToText)) + { + $btnTextClass = 'text-primary'; + $assignedToText = $this->lang->task->noAssigned; + } + else if ($assignedToText == $account) $btnTextClass = 'text-red'; + $btnClass = $assignedToText == 'closed' ? ' disabled' : ''; + + echo html::a(helper::createLink('task', 'assignTo', "projectID=$task->project&taskID=$task->id"), " {$assignedToText}", '', "class='iframe btn btn-icon-left{$btnClass}'"); break; case 'assignedDate': echo substr($task->assignedDate, 5, 11); diff --git a/www/js/zui/min.js b/www/js/zui/min.js index e3ce8eb64c..785e23949a 100644 --- a/www/js/zui/min.js +++ b/www/js/zui/min.js @@ -16,7 +16,7 @@ function(t,e,i){"$:nomunge";function s(){n=e[r](function(){a.each(function(){var * Copyright 2006, 2014 Klaus Hartl * Released under the MIT license */ -function(t){"function"==typeof define&&define.amd?define(["jquery"],t):t("object"==typeof exports?require("jquery"):jQuery)}(function(t){function e(t){return r.raw?t:encodeURIComponent(t)}function i(t){return r.raw?t:decodeURIComponent(t)}function s(t){return e(r.json?JSON.stringify(t):String(t))}function n(t){0===t.indexOf('"')&&(t=t.slice(1,-1).replace(/\\"/g,'"').replace(/\\\\/g,"\\"));try{return t=decodeURIComponent(t.replace(o," ")),r.json?JSON.parse(t):t}catch(e){}}function a(e,i){var s=r.raw?e:n(e);return t.isFunction(i)?i(s):s}var o=/\+/g,r=t.cookie=function(n,o,l){if(void 0!==o&&!t.isFunction(o)){if(l=t.extend({},r.defaults,l),"number"==typeof l.expires){var h=l.expires,c=l.expires=new Date;c.setTime(+c+864e5*h)}return document.cookie=[e(n),"=",s(o),l.expires?"; expires="+l.expires.toUTCString():"",l.path?"; path="+l.path:"",l.domain?"; domain="+l.domain:"",l.secure?"; secure":""].join("")}for(var d=n?void 0:{},u=document.cookie?document.cookie.split("; "):[],p=0,f=u.length;p=0;t--)delete this.page[i[t]];this.set(a,this.page)}},o.prototype.pageRemove=function(t){"undefined"!=typeof this.page[t]&&(this.page[t]=null,this.pageSave())},o.prototype.pageClear=function(){this.page={},this.pageSave()},o.prototype.pageGet=function(t,e){var i=this.page[t];return void 0===e||null!==i&&void 0!==i?i:e},o.prototype.pageSet=function(t,i){e.isPlainObject(t)?e.extend(!0,this.page,t):this.page[this.serialize(t)]=i,this.pageSave()},o.prototype.check=function(){if(!this.enable&&!this.slience)throw new Error("Browser not support localStorage or enable status been set true.");return this.enable},o.prototype.length=function(){return this.check()?i.getLength?i.getLength():i.length:0},o.prototype.removeItem=function(t){return i.removeItem(t),this},o.prototype.remove=function(t){return this.removeItem(t)},o.prototype.getItem=function(t){return i.getItem(t)},o.prototype.get=function(t,e){var i=this.deserialize(this.getItem(t));return"undefined"!=typeof i&&null!==i||"undefined"==typeof e?i:e},o.prototype.key=function(t){return i.key(t)},o.prototype.setItem=function(t,e){return i.setItem(t,e),this},o.prototype.set=function(t,e){return void 0===e?this.remove(t):(this.setItem(t,this.serialize(e)),this)},o.prototype.clear=function(){return i.clear(),this},o.prototype.forEach=function(t){for(var e=this.length(),s=e-1;s>=0;s--){var n=i.key(s);t(n,this.get(n))}return this},o.prototype.getAll=function(){var t={};return this.forEach(function(e,i){t[e]=i}),t},o.prototype.serialize=function(t){return"string"==typeof t?t:JSON.stringify(t)},o.prototype.deserialize=function(t){if("string"==typeof t)try{return JSON.parse(t)}catch(e){return t||void 0}},e.zui({store:new o})}(window,jQuery),function(t){"use strict";var e="zui.searchBox",i=function(e,s){var n=this;n.name=name,n.$=t(e),n.options=s=t.extend({},i.DEFAULTS,n.$.data(),s);var a=n.$.is(s.inputSelector)?n.$:n.$.find(s.inputSelector);if(a.length){var o=function(){n.changeTimer&&(clearTimeout(n.changeTimer),n.changeTimer=null)},r=function(){o();var t=n.getSearch();if(t!==n.lastValue){var e=""===t;a.toggleClass("empty",e),n.$.callComEvent(n,"onSearchChange",[t,e]),n.lastValue=t}};n.$input=a=a.first(),n.lastValue=n.getSearch(),a.on(s.listenEvent,function(t){n.changeTimer=setTimeout(function(){r()},s.changeDelay)}).on("focus",function(t){a.addClass("focus"),n.$.callComEvent(n,"onFocus",[t])}).on("blur",function(t){a.removeClass("focus"),n.$.callComEvent(n,"onBlur",[t])}).on("keydown",function(t){var e=0,i=t.which;27===i&&s.escToClear?(this.setSearch("",!0),r(),e=1):13===i&&s.onPressEnter&&(r(),n.$.callComEvent(n,"onPressEnter",[t]));var a=n.$.callComEvent(n,"onKeyDown",[t]);a===!1&&(e=1),e&&t.preventDefault()}),n.$.on("click",".search-clear-btn",function(t){n.setSearch("",!0),r(),t.preventDefault()}),r()}else console.error("ZUI: search box init error, cannot find search box input element.")};i.DEFAULTS={inputSelector:'input[type="search"],input[type="text"]',listenEvent:"change input paste",changeDelay:500},i.prototype.getSearch=function(){return this.$input&&t.trim(this.$input.val())},i.prototype.setSearch=function(t,e){var i=this.$input;i&&(i.val(t),e||i.trigger("change"))},i.prototype.focus=function(){this.$input&&this.$input.focus()},t.fn.searchBox=function(s){return this.each(function(){var n=t(this),a=n.data(e),o="object"==typeof s&&s;a||n.data(e,a=new i(this,o)),"string"==typeof s&&a[s]()})},i.NAME=e,t.fn.searchBox.Constructor=i}(jQuery),function(t,e){"use strict";var i="zui.draggable",s={container:"body",move:!0},n=0,a=function(e,i){var a=this;a.$=t(e),a.id=n++,a.options=t.extend({},s,a.$.data(),i),a.init()};a.DEFAULTS=s,a.NAME=i,a.prototype.init=function(){var s,n,a,o,r,l=this,h=l.$,c="before",d="drag",u="finish",p="."+i+"."+l.id,f="mousedown"+p,g="mouseup"+p,m="mousemove"+p,v=l.options,y=v.selector,b=v.handle,w=h,x=t.isFunction(v.move),_=function(t){var e=t.pageX,i=t.pageY;r=!0;var n={left:e-a.x,top:i-a.y};w.removeClass("drag-ready").addClass("dragging"),v.move&&(x?v.move(n,w):w.css(n)),v[d]&&v[d]({event:t,element:w,startOffset:a,pos:n,offset:{x:e-s.x,y:i-s.y},smallOffset:{x:e-o.x,y:i-o.y}}),o.x=e,o.y=i,v.stopPropagation&&t.stopPropagation()},C=function(i){if(t(e).off(p),!r)return void w.removeClass("drag-ready");var n={left:i.pageX-a.x,top:i.pageY-a.y};w.removeClass("drag-ready dragging"),v.move&&(x?v.move(n,w):w.css(n)),v[u]&&v[u]({event:i,element:w,startOffset:a,pos:n,offset:{x:i.pageX-s.x,y:i.pageY-s.y},smallOffset:{x:i.pageX-o.x,y:i.pageY-o.y}}),i.preventDefault(),v.stopPropagation&&i.stopPropagation()},k=function(i){var l=t.zui.getMouseButtonCode(v.mouseButton);if(!(l>-1&&i.button!==l)){var h=t(this);if(y&&(w=b?h.closest(y):h),v[c]){var d=v[c]({event:i,element:w});if(d===!1)return}var u=t(v.container),p=w.offset();n=u.offset(),s={x:i.pageX,y:i.pageY},a={x:i.pageX-p.left+n.left,y:i.pageY-p.top+n.top},o=t.extend({},s),r=!1,w.addClass("drag-ready"),i.preventDefault(),v.stopPropagation&&i.stopPropagation(),t(e).on(m,_).on(g,C)}};b?h.on(f,b,k):y?h.on(f,y,k):h.on(f,k)},a.prototype.destroy=function(){var s="."+i+"."+this.id;this.$.off(s),t(e).off(s),this.$.data(i,null)},t.fn.draggable=function(e){return this.each(function(){var s=t(this),n=s.data(i),o="object"==typeof e&&e;n||s.data(i,n=new a(this,o)),"string"==typeof e&&n[e]()})},t.fn.draggable.Constructor=a}(jQuery,document),function(t,e,i){"use strict";var s="zui.droppable",n={target:".droppable-target",deviation:5,sensorOffsetX:0,sensorOffsetY:0},a=0,o=function(e,i){var s=this;s.id=a++,s.$=t(e),s.options=t.extend({},n,s.$.data(),i),s.init()};o.DEFAULTS=n,o.NAME=s,o.prototype.trigger=function(e,i){return t.zui.callEvent(this.options[e],i,this)},o.prototype.init=function(){var n,a,o,r,l,h,c,d,u,p,f,g,m,v=this,y=v.$,b=v.options,w=b.deviation,x="."+s+"."+v.id,_="mousedown"+x,C="mouseup"+x,k="mousemove"+x,T=b.selector,S=b.handle,D=b.flex,M=b.container,P=b.canMoveHere,F=y,z=!1,L=M?t(b.container).first():T?y:t("body"),$=function(e){if(z&&(f={left:e.pageX,top:e.pageY},!(i.abs(f.left-d.left)a&&f.top>o&&f.left-1&&i.button!==s)){var f=t(this);T&&(F=S?f.closest(T):f),F.hasClass("drag-shadow")||b.before&&b.before({event:i,element:F})===!1||(z=!0,n=t.isFunction(b.target)?b.target(F,y):L.find(b.target),a=null,o=null,r=!1,l=!0,h=null,c=F.offset(),u=L.offset(),d={left:i.pageX,top:i.pageY},g=t.extend({},d),p={left:d.left-c.left,top:d.top-c.top},F.addClass("drag-from"),t(e).on(k,$).on(C,E),m=setTimeout(function(){t(e).on(_,E)},10),i.preventDefault())}};S?y.on(_,S,I):T?y.on(_,T,I):y.on(_,I)},o.prototype.destroy=function(){var i="."+s+"."+this.id;this.$.off(i),t(e).off(i),this.$.data(s,null)},o.prototype.reset=function(){this.destroy(),this.init()},t.fn.droppable=function(e){return this.each(function(){var i=t(this),n=i.data(s),a="object"==typeof e&&e;n||i.data(s,n=new o(this,a)),"string"==typeof e&&n[e]()})},t.fn.droppable.Constructor=o}(jQuery,document,Math),+function(t,e){"use strict";function i(e,i,a){return this.each(function(){var o=t(this),r=o.data(s),l=t.extend({},n.DEFAULTS,o.data(),"object"==typeof e&&e);r||o.data(s,r=new n(this,l)),"string"==typeof e?r[e](i,a):l.show&&r.show(i,a)})}var s="zui.modal",n=function(i,n){var a=this;a.options=n,a.$body=t(document.body),a.$element=t(i),a.$backdrop=a.isShown=null,a.scrollbarWidth=0,n.moveable===e&&(a.options.moveable=a.$element.hasClass("modal-moveable")),n.remote&&a.$element.find(".modal-content").load(n.remote,function(){a.$element.trigger("loaded."+s)})};n.VERSION="3.2.0",n.TRANSITION_DURATION=300,n.BACKDROP_TRANSITION_DURATION=150,n.DEFAULTS={backdrop:!0,keyboard:!0,show:!0,position:"fit"};var a=function(e,i){var s=t(window);i.left=Math.max(0,Math.min(i.left,s.width()-e.outerWidth())),i.top=Math.max(0,Math.min(i.top,s.height()-e.outerHeight())),e.css(i)};n.prototype.toggle=function(t,e){return this.isShown?this.hide():this.show(t,e)},n.prototype.ajustPosition=function(i){var n=this,o=n.options;if(i===e&&(i=o.position),i!==e){t.isFunction(i)&&(i=i(n));var r=n.$element.find(".modal-dialog"),l=Math.max(0,(t(window).height()-r.outerHeight())/2);if("fit"===i?i={top:Math.floor(2*l/3)}:"center"===i?i={top:l}:t.isPlainObject(i)||(i={top:i}),r.hasClass("modal-moveable")){var h=null,c=o.rememberPos;c&&(c===!0?h=n.$element.data("modal-pos"):t.zui.store&&(h=t.zui.store.pageGet(s+".rememberPos."+c))),i=t.extend(i,{left:Math.max(0,(t(window).width()-r.outerWidth())/2)},h),"inside"===o.moveable?a(r,i):r.css(i)}else r.css(i)}},n.prototype.setMoveale=function(){t.fn.draggable||console.error("Moveable modal requires draggable.js.");var e=this,i=e.options,n=e.$element.find(".modal-dialog").removeClass("modal-dragged");n.toggleClass("modal-moveable",!!i.moveable),e.$element.data("modal-moveable-setup")||n.draggable({container:e.$element,handle:".modal-header",before:function(){var t=n.css("margin-top");t&&"0px"!==t&&n.css("top",t).css("margin-top","").addClass("modal-dragged")},finish:function(n){var a=i.rememberPos;a&&(e.$element.data("modal-pos",n.pos),t.zui.store&&a!==!0&&t.zui.store.pageSet(s+".rememberPos."+a,n.pos))},move:"inside"!==i.moveable||function(t){a(n,t)}})},n.prototype.show=function(e,i){var a=this,o=t.Event("show."+s,{relatedTarget:e});a.$element.trigger(o),a.isShown||o.isDefaultPrevented()||(a.isShown=!0,a.options.moveable&&a.setMoveale(),a.checkScrollbar(),a.options.backdrop!==!1&&(a.$body.addClass("modal-open"),a.setScrollbar()),a.escape(),a.$element.on("click.dismiss."+s,'[data-dismiss="modal"]',t.proxy(a.hide,a)),a.backdrop(function(){var o=t.support.transition&&a.$element.hasClass("fade");a.$element.parent().length||a.$element.appendTo(a.$body),a.$element.show().scrollTop(0),o&&a.$element[0].offsetWidth,a.$element.addClass("in").attr("aria-hidden",!1),a.ajustPosition(i),a.enforceFocus();var r=t.Event("shown."+s,{relatedTarget:e});o?a.$element.find(".modal-dialog").one("bsTransitionEnd",function(){a.$element.trigger("focus").trigger(r)}).emulateTransitionEnd(n.TRANSITION_DURATION):a.$element.trigger("focus").trigger(r)}))},n.prototype.hide=function(e){e&&e.preventDefault();var i=this;e=t.Event("hide."+s),i.$element.trigger(e),i.isShown&&!e.isDefaultPrevented()&&(i.isShown=!1,i.options.backdrop!==!1&&(i.$body.removeClass("modal-open"),i.resetScrollbar()),i.escape(),t(document).off("focusin."+s),i.$element.removeClass("in").attr("aria-hidden",!0).off("click.dismiss."+s),t.support.transition&&i.$element.hasClass("fade")?i.$element.one("bsTransitionEnd",t.proxy(i.hideModal,i)).emulateTransitionEnd(n.TRANSITION_DURATION):i.hideModal())},n.prototype.enforceFocus=function(){t(document).off("focusin."+s).on("focusin."+s,t.proxy(function(t){this.$element[0]===t.target||this.$element.has(t.target).length||this.$element.trigger("focus")},this))},n.prototype.escape=function(){this.isShown&&this.options.keyboard?t(document).on("keydown.dismiss."+s,t.proxy(function(i){if(27==i.which){var n=t.Event("escaping."+s),a=this.$element.triggerHandler(n,"esc");if(a!=e&&!a)return;this.hide()}},this)):this.isShown||t(document).off("keydown.dismiss."+s)},n.prototype.hideModal=function(){var t=this;this.$element.hide(),this.backdrop(function(){t.$element.trigger("hidden."+s)})},n.prototype.removeBackdrop=function(){this.$backdrop&&this.$backdrop.remove(),this.$backdrop=null},n.prototype.backdrop=function(e){var i=this,a=this.$element.hasClass("fade")?"fade":"";if(this.isShown&&this.options.backdrop){var o=t.support.transition&&a;if(this.$backdrop=t('