/*! jQuery v1.11.1 | (c) 2005, 2014 jQuery Foundation, Inc. | jquery.org/license */ /*! jQuery UI - v1.11.2 - 2014-10-24 * http://jqueryui.com * Includes: core.js, widget.js, mouse.js, position.js, draggable.js, resizable.js, selectable.js, sortable.js, autocomplete.js, menu.js, progressbar.js, slider.js * Copyright 2014 jQuery Foundation and other contributors; Licensed MIT */ // Underscore.js 1.6.0 // http://underscorejs.org // (c) 2009-2014 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors // Underscore may be freely distributed under the MIT license. /************************************************************************* * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2014 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and are protected by all applicable intellectual property laws, * including trade secret and or copyright laws. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2013 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and are protected by all applicable intellectual property laws, * including trade secret and or copyright laws. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ // (c) 2010-2014 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors // Backbone may be freely distributed under the MIT license. // For all details and documentation: // http://backbonejs.org /************************************************************************* * * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2012 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and may be covered by U.S. and Foreign Patents, * patents in process, and are protected by trade secret or copyright law. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /** * @license RequireJS i18n 2.0.4 Copyright (c) 2010-2012, The Dojo Foundation All Rights Reserved. * Available via the MIT or new BSD license. * see: http://github.com/requirejs/i18n for details */ // /************************************************************************* // * // * ADOBE CONFIDENTIAL // * ___________________ // * // * Copyright 2012 Adobe Systems Incorporated // * All Rights Reserved. // * // * NOTICE: All information contained herein is, and remains // * the property of Adobe Systems Incorporated and its suppliers, // * if any. The intellectual and technical concepts contained // * herein are proprietary to Adobe Systems Incorporated and its // * suppliers and may be covered by U.S. and Foreign Patents, // * patents in process, and are protected by trade secret or copyright law. // * Dissemination of this information or reproduction of this material // * is strictly forbidden unless prior written permission is obtained // * from Adobe Systems Incorporated. // **************************************************************************/ //! moment.js //! version : 2.8.3 //! authors : Tim Wood, Iskren Chernev, Moment.js contributors //! license : MIT //! momentjs.com /************************************************************************* * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2015 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and are protected by all applicable intellectual property laws, * including trade secret and or copyright laws. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2014 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and are protected by all applicable intellectual property laws, * including trade secret and or copyright laws. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2018 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and are protected by all applicable intellectual property laws, * including trade secret and or copyright laws. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2019 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and are protected by all applicable intellectual property laws, * including trade secret and or copyright laws. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2013 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and may be covered by U.S. and Foreign Patents, * patents in process, and are protected by trade secret or copyright law. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2014 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and may be covered by U.S. and Foreign Patents, * patents in process, and are protected by trade secret or copyright law. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2014 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and may be covered by U.S. and Foreign Patents, * patents in process, and are protected by trade secret or copyright law. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ // Copyright (C) 2006 Google Inc. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. // Copyright Google Inc. // Licensed under the Apache Licence Version 2.0 // Autogenerated at Tue Jun 17 02:31:43 PDT 2014 // @overrides window // @provides html4 // Copyright Google Inc. /************************************************************************* * * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2012 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and may be covered by U.S. and Foreign Patents, * patents in process, and are protected by trade secret or copyright law. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2013 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and may be covered by U.S. and Foreign Patents, * patents in process, and are protected by trade secret or copyright law. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2013 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and are protected by all applicable intellectual property laws, * including trade secret and or copyright laws. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2014 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and may be covered by U.S. and Foreign Patents, * patents in process, and are protected by trade secret or copyright law. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2018 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and may be covered by U.S. and Foreign Patents, * patents in process, and are protected by trade secret or copyright law. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2020 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and are protected by all applicable intellectual property * laws, including trade secret and copyright laws. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2019 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and are protected by all applicable intellectual property laws, * including trade secret and or copyright laws. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /*! * @overview es6-promise - a tiny implementation of Promises/A+. * @copyright Copyright (c) 2014 Yehuda Katz, Tom Dale, Stefan Penner and contributors (Conversion to ES6 API by Jake Archibald) * @license Licensed under MIT license * See https://raw.githubusercontent.com/stefanpenner/es6-promise/master/LICENSE * @version 4.1.0 */ /************************************************************************* * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2013 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and are protected by all applicable intellectual property * laws, including trade secret and copyright laws. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2014 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and are protected by all applicable intellectual property * laws, including trade secret and copyright laws. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2019 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and may be covered by U.S. and Foreign Patents, * patents in process, and are protected by trade secret or copyright law. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2019 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and are protected by all applicable intellectual property * laws, including trade secret and copyright laws. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2019 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and are protected by all applicable intellectual property laws, * including trade secret and or copyright laws. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2015 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and may be covered by U.S. and Foreign Patents, * patents in process, and are protected by trade secret or copyright law. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * * ADOBE CONFIDENTIAL * ___________________ * * Copyright 201 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and may be covered by U.S. and Foreign Patents, * patents in process, and are protected by trade secret or copyright law. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2015 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and are protected by all applicable intellectual property laws, * including trade secret and or copyright laws. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2018 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and are protected by all applicable intellectual property laws, * including trade secret and or copyright laws. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2013 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and may be covered by U.S. and Foreign Patents, * patents in process, and are protected by trade secret or copyright law. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /************************************************************************* * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2015 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and are protected by all applicable intellectual property * laws, including trade secret and copyright laws. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /*! * jQuery Cookie Plugin v1.4.1 * https://github.com/carhartl/jquery-cookie * * Copyright 2006, 2014 Klaus Hartl * Released under the MIT license */ /************************************************************************* * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2013 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and are protected by all applicable intellectual property * laws, including trade secret and copyright laws. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /*! jQuery UI - v1.11.1 - 2014-09-17 * http://jqueryui.com * Includes: widget.js * Copyright 2014 jQuery Foundation and other contributors; Licensed MIT */ /*! * jQuery UI Widget 1.11.1 * http://jqueryui.com * * Copyright 2014 jQuery Foundation and other contributors * Released under the MIT license. * http://jquery.org/license * * http://api.jqueryui.com/jQuery.widget/ */ /* * jQuery File Upload Plugin 5.42.0 * https://github.com/blueimp/jQuery-File-Upload * * Copyright 2010, Sebastian Tschan * https://blueimp.net * * Licensed under the MIT license: * http://www.opensource.org/licenses/MIT */ /* * jQuery Iframe Transport Plugin 1.8.2 * https://github.com/blueimp/jQuery-File-Upload * * Copyright 2011, Sebastian Tschan * https://blueimp.net * * Licensed under the MIT license: * http://www.opensource.org/licenses/MIT */ /************************************************************************* * * ADOBE CONFIDENTIAL * ___________________ * * Copyright 2017 Adobe Systems Incorporated * All Rights Reserved. * * NOTICE: All information contained herein is, and remains * the property of Adobe Systems Incorporated and its suppliers, * if any. The intellectual and technical concepts contained * herein are proprietary to Adobe Systems Incorporated and its * suppliers and may be covered by U.S. and Foreign Patents, * patents in process, and are protected by trade secret or copyright law. * Dissemination of this information or reproduction of this material * is strictly forbidden unless prior written permission is obtained * from Adobe Systems Incorporated. **************************************************************************/ /** * SHA256 Hash Algorithm Plugin * * @version 1.1 (17/08/2012) * @requires jQuery v1.2.6+ * @author Alex Weber * @copyright Copyright (c) 2008-2009, Alex Weber * @see http://anmar.eu.org/projects/jssha2/ * @see http://pajhome.org.uk/crypt/md5 * * Distributed under the terms of the new BSD License * http://www.opensource.org/licenses/bsd-license.php * */ !function(e,t){"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(e,t){function g(e){var t=e.length,n=h.type(e);return"function"===n||h.isWindow(e)?!1:1===e.nodeType&&t?!0:"array"===n||0===t||"number"==typeof t&&t>0&&t-1 in e}function S(e,t,n){if(h.isFunction(t))return h.grep(e,function(e,r){return!!t.call(e,r,e)!==n});if(t.nodeType)return h.grep(e,function(e){return e===t!==n});if("string"==typeof t){if(E.test(t))return h.filter(t,e,n);t=h.filter(t,e)}return h.grep(e,function(e){return h.inArray(e,t)>=0!==n})}function A(e,t){do e=e[t];while(e&&1!==e.nodeType);return e}function _(e){var t=M[e]={};return h.each(e.match(O)||[],function(e,n){t[n]=!0}),t}function P(){T.addEventListener?(T.removeEventListener("DOMContentLoaded",H,!1),e.removeEventListener("load",H,!1)):(T.detachEvent("onreadystatechange",H),e.detachEvent("onload",H))}function H(){(T.addEventListener||"load"===event.type||"complete"===T.readyState)&&(P(),h.ready())}function q(e,t,n){if(void 0===n&&1===e.nodeType){var r="data-"+t.replace(I,"-$1").toLowerCase();if(n=e.getAttribute(r),"string"==typeof n){try{n="true"===n?!0:"false"===n?!1:"null"===n?null:+n+""===n?+n:F.test(n)?h.parseJSON(n):n}catch(i){}h.data(e,t,n)}else n=void 0}return n}function R(e){var t;for(t in e)if(("data"!==t||!h.isEmptyObject(e[t]))&&"toJSON"!==t)return!1;return!0}function U(e,t,r,i){if(h.acceptData(e)){var s,o,u=h.expando,a=e.nodeType,f=a?h.cache:e,l=a?e[u]:e[u]&&u;if(l&&f[l]&&(i||f[l].data)||void 0!==r||"string"!=typeof t)return l||(l=a?e[u]=n.pop()||h.guid++:u),f[l]||(f[l]=a?{}:{toJSON:h.noop}),("object"==typeof t||"function"==typeof t)&&(i?f[l]=h.extend(f[l],t):f[l].data=h.extend(f[l].data,t)),o=f[l],i||(o.data||(o.data={}),o=o.data),void 0!==r&&(o[h.camelCase(t)]=r),"string"==typeof t?(s=o[t],null==s&&(s=o[h.camelCase(t)])):s=o,s}}function z(e,t,n){if(h.acceptData(e)){var r,i,s=e.nodeType,o=s?h.cache:e,u=s?e[h.expando]:h.expando;if(o[u]){if(t&&(r=n?o[u]:o[u].data)){h.isArray(t)?t=t.concat(h.map(t,h.camelCase)):t in r?t=[t]:(t=h.camelCase(t),t=t in r?[t]:t.split(" ")),i=t.length;while(i--)delete r[t[i]];if(n?!R(r):!h.isEmptyObject(r))return}(n||(delete o[u].data,R(o[u])))&&(s?h.cleanData([e],!0):l.deleteExpando||o!=o.window?delete o[u]:o[u]=null)}}}function et(){return!0}function tt(){return!1}function nt(){try{return T.activeElement}catch(e){}}function rt(e){var t=it.split("|"),n=e.createDocumentFragment();if(n.createElement)while(t.length)n.createElement(t.pop());return n}function wt(e,t){var n,r,i=0,s=typeof e.getElementsByTagName!==B?e.getElementsByTagName(t||"*"):typeof e.querySelectorAll!==B?e.querySelectorAll(t||"*"):void 0;if(!s)for(s=[],n=e.childNodes||e;null!=(r=n[i]);i++)!t||h.nodeName(r,t)?s.push(r):h.merge(s,wt(r,t));return void 0===t||t&&h.nodeName(e,t)?h.merge([e],s):s}function Et(e){J.test(e.type)&&(e.defaultChecked=e.checked)}function St(e,t){return h.nodeName(e,"table")&&h.nodeName(11!==t.nodeType?t:t.firstChild,"tr")?e.getElementsByTagName("tbody")[0]||e.appendChild(e.ownerDocument.createElement("tbody")):e}function xt(e){return e.type=(null!==h.find.attr(e,"type"))+"/"+e.type,e}function Tt(e){var t=vt.exec(e.type);return t?e.type=t[1]:e.removeAttribute("type"),e}function Nt(e,t){for(var n,r=0;null!=(n=e[r]);r++)h._data(n,"globalEval",!t||h._data(t[r],"globalEval"))}function Ct(e,t){if(1===t.nodeType&&h.hasData(e)){var n,r,i,s=h._data(e),o=h._data(t,s),u=s.events;if(u){delete o.handle,o.events={};for(n in u)for(r=0,i=u[n].length;i>r;r++)h.event.add(t,n,u[n][r])}o.data&&(o.data=h.extend({},o.data))}}function kt(e,t){var n,r,i;if(1===t.nodeType){if(n=t.nodeName.toLowerCase(),!l.noCloneEvent&&t[h.expando]){i=h._data(t);for(r in i.events)h.removeEvent(t,r,i.handle);t.removeAttribute(h.expando)}"script"===n&&t.text!==e.text?(xt(t).text=e.text,Tt(t)):"object"===n?(t.parentNode&&(t.outerHTML=e.outerHTML),l.html5Clone&&e.innerHTML&&!h.trim(t.innerHTML)&&(t.innerHTML=e.innerHTML)):"input"===n&&J.test(e.type)?(t.defaultChecked=t.checked=e.checked,t.value!==e.value&&(t.value=e.value)):"option"===n?t.defaultSelected=t.selected=e.defaultSelected:("input"===n||"textarea"===n)&&(t.defaultValue=e.defaultValue)}}function Ot(t,n){var r,i=h(n.createElement(t)).appendTo(n.body),s=e.getDefaultComputedStyle&&(r=e.getDefaultComputedStyle(i[0]))?r.display:h.css(i[0],"display");return i.detach(),s}function Mt(e){var t=T,n=At[e];return n||(n=Ot(e,t),"none"!==n&&n||(Lt=(Lt||h("').bind("load",function(){var t,o=e.isArray(n.paramName)?n.paramName:[n.paramName];s.unbind("load").bind("load",function(){var t;try{t=s.contents();if(!t.length||!t[0].firstChild)throw new Error}catch(n){t=undefined}a(200,"success",{iframe:t}),e('').appendTo(i),window.setTimeout(function(){i.remove()},0)}),i.prop("target",s.prop("name")).prop("action",n.url).prop("method",n.type),n.formData&&e.each(n.formData,function(t,n){e('').prop("name",n.name).val(n.value).appendTo(i)}),n.fileInput&&n.fileInput.length&&n.type==="POST"&&(t=n.fileInput.clone(),n.fileInput.after(function(e){return t[e]}),n.paramName&&n.fileInput.each(function(t){e(this).prop("name",o[t]||n.paramName)}),i.append(n.fileInput).prop("enctype","multipart/form-data").prop("encoding","multipart/form-data"),n.fileInput.removeAttr("form")),i.submit(),t&&t.length&&n.fileInput.each(function(n,r){var i=e(t[n]);e(r).prop("name",i.prop("name")).attr("form",i.attr("form")),i.replaceWith(r)})}),i.append(s).appendTo(document.body)},abort:function(){s&&s.unbind("load").prop("src",r),i&&i.remove()}}}}),e.ajaxSetup({converters:{"iframe text":function(t){return t&&e(t[0].body).text()},"iframe json":function(t){return t&&e.parseJSON(e(t[0].body).text())},"iframe html":function(t){return t&&e(t[0].body).html()},"iframe xml":function(t){var n=t&&t[0];return n&&e.isXMLDoc(n)?n:e.parseXML(n.XMLDocument&&n.XMLDocument.xml||e(n.body).html())},"iframe script":function(t){return t&&e.globalEval(e(t[0].body).text())}}})}),define("files/dev/templates/file-upload-progress-template",[],function(){return'
<%= uploadHeading %>
<%- fileName %>
'}),define("files/dev/views/file-upload-progress-view",["core/ac-core","files/ac-files","files/templates/file-upload-progress-template","i18n!files/nls/ui-strings","core/utils/truncate","core/utils/view-util","core/views/view"],function(e,t,n,r,i,s){return t.FileUploadProgressView=e.View.extend({events:{"click .file-upload-cancel":"_onFileUploadCancel"},initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(n),this._numFailures=0},render:function(){e.View.prototype.render.call(this);if(s.isElementHidden(this.$el))return;return this.$progressBar||(this.$el.empty().html(this._template({fileName:this._getFileName(),uploadHeading:this._getStatus(),viewId:this.options.viewId})),this._initWrappers()),Ac.Locale.getLocale()==="ja-jp"&&this.$fileName.addClass("jp"),this._updateProgressAll(),this._updateHeader(),this._updateFileName(),this._isUploading=!0,this._updateCancelBtn(),this},setFiles:function(e){this._resetState(),this._files=e,this._numFiles=e.length,_.defer(this.render)},setNumFiles:function(e){this._numFiles=e,this.render()},getNumFiles:function(){return this._numFiles||0},setProgressAll:function(e,t){this._loaded=e,this._total=t,this._loaded===this._total&&(this._isUploadComplete=!0),this.render()},close:function(){this._resetState()},_onFileUploadCancel:function(){var e=this.options.fileUploadUiModel,t;e&&(t=this.options.fileUploadUiModel.get("jq_xhr"),t&&t.abort()),this.close()},_initWrappers:function(){this.$toolsContent=$(".tools-content"),this.$progressBar=this.$(".file-upload-progress-bar"),this.$progressLoaded=this.$(".file-upload-progress-bar-loaded"),this.$fileName=this.$(".file-upload-progress-file-name"),this.$header=this.$(".file-upload-progress-header"),this.$cancel=this.$(".file-upload-cancel")},_getStatus:function(){return this._isUploadComplete?r.PROCESSING:r.UPLOADING},_getFileName:function(){var e="",t=this._files,n=this._numFiles;return n===1?t&&t.length>0&&(e=t[0].name):e=_.template(r.N_FILES,{numFiles:n}),e},_resetState:function(){this._isUploading=undefined,this._isUploadComplete=undefined,this._files=undefined,this._numFiles=0,this._numFailures=0,this._loaded=undefined,this._total=undefined},_updateProgressAll:function(){var e,t=this._loaded,n=this._total,r;if(this.options.fileUploadModel.hasAjaxFileUpload()&&!t)return;t0}));if(n.length===0)return!1;if(!i.fileUploadUiModel.get("is_uploading")&&s.dialogApi.isDialogOpen())return!1;this._logEventTypeAndNames(e,t);if(this._isFolderUpload(e,t))return s.errorApi.enqueueAjaxError({status:"folder-upload-not-supported"}),this._decrementNumFiles(),!1;i.enableDragAndDrop?u=s.folderApi.getRootFolderId(i.pluginId):u=i.folderModel.get("id"),t.formData=i.fileUploadModel.getFormData(t,u)},_onFileUploadSend:function(e,t){this._logEventTypeAndNames(e,t),r.isCEF()?t.headers=_.pick(i.getRequestHeaders("POST"),"Accept","x-csrftoken","Authorization"):t.headers=_.pick(i.getRequestHeaders("POST"),"Accept","x-csrftoken"),t.global=!1,_.isFunction(t.xhr)&&this.options.fileUploadUiModel.set("jq_xhr",t.xhr())},_onFileUploadChange:function(e,t){this._logEventTypeAndNames(e,t),this._initFiles(t)},_onFileUploadPaste:function(e,t){var n=t.files;n&&n.length>0&&this._logEventTypeAndNames(e,t)},_onFileUploadDrop:function(e,t){this._logEventTypeAndNames(e,t),this._initFiles(t),this._isDragOverLogged=!1},_onFileUploadDragOver:function(){this._isDragOverLogged||(this._isDragOverLogged=!0)},_onFileUploadProgress:function(e,t){this._logProgressName(e,t)},_onFileUploadProgressAll:function(e,t){this._logProgress(e,t),this._progressView&&this._progressView.setProgressAll(t.loaded,t.total)},_onFileUploadDone:function(e,t){var n=this.options,r,i,s,o;f+=1,f===a&&(r=n.appApi.pluginsApi.callPluginMethod(n.pluginId,"_getSiteCatalystContext",undefined,u.FILE_LIST,!0),i=[r,u.UPLOAD],this._logSiteCatalystEvent(i.concat(u.SUCCESS)),this._logSiteCatalystEvent(i.concat([u.NUM_FILES,u.getCountCode(a)]))),s=t.jqXHR.responseText;if(s&&s.length>0)try{o=JSON.parse(s)}catch(l){}o&&o.renamed_to&&o.renamed_details.duplicate_of&&(o.object_type="file",this._onFileUploadDuplicateName(o))},_onFileUploadDuplicateName:function(t){if(r.isIpad()||r.isIphone())return;t.dupType=e.ErrorUiModel.DUP_TYPE_UPLOAD,this.options.errorUiModel.enqueueDupError(t,!0)},_onFileUploadFail:function(t,n){var r=n.jqXHR,i=this.options.appApi.errorApi;if(e.Features.isFeatureEnabled("quota_ui")&&i.isQuotaExceededError(r)){i.enqueueQuotaError();return}r.status>0&&i.enqueueAjaxError(r),this._decrementNumFiles()},_onFileUploadAlways:function(e,t){return undefined},_isFolderUpload:function(e,t){var n=this.options.appApi.displayApi;return!!_.find(t.files,function(e){return n.isDebugLogging()&&r.logProperties(e),e.relativePath||!e.type&&e.size%4096===0&&r.getExtension(e.name)!=="indd"})},_initFiles:function(e){var t=this._progressView,n,r,i;n=this._files=e.files,r=this._numFiles=n.length,a+=r,t&&(i=t.getNumFiles(),t.setFiles(n),t.setNumFiles(i+r))},_decrementNumFiles:function(){var e=this._progressView,t;this._numFiles-=1,t=this._numFiles,t===0?this._closeProgressView():e&&e.setNumFiles(t)},_dequeueFileUploadError:function(){var e=this.options;e.errorUiModel.dequeueDupError()||e.appApi.errorApi.dequeueQuotaError()},_addPostMessageListener:function(){if(this._isListeningForPostMessage)return;this._isListeningForPostMessage=!0,s.addPostMessageListener(this._onReceiveMessage)},_onReceiveMessage:function(t){var n,r,i,s,o,u;n=e.getBaseCloudUrl();if(!n||n.indexOf(t.origin)!==0)return;try{r=JSON.parse(t.data)}catch(a){return}if(r.name!=="complete-file-upload")return;try{i=JSON.parse(r.response)}catch(a){return}s=i.status,o=i.body,u=this.options,o.error?(u.appApi.errorApi.enqueueAjaxError({status:s,responseText:JSON.stringify({error:{code:o.error.code}})}),this._decrementNumFiles()):o.renamed_to&&o.renamed_details.duplicate_of&&(o.object_type="file",this._onFileUploadDuplicateName(o),u.fileUploadUiModel.get("is_uploading")||this._dequeueFileUploadError())},_openProgressView:function(){var e=this.options,r=e.appApi,i,s=r.statusMenuApi;return e=_.extend({},e,{parentView:e.rootView,showCancelBtn:!0}),delete e.el,this._progressView||(this._progressView=new t.FileUploadProgressView(e)),i=this._progressView,i.setFiles(this._files),s.showStatusMenuItem(n.HOME).then(function(e){i.setElement(e)}),s.setStatus(n.HOME,{status:r.statusMenuApi.STATUS_BUSY}),i},_closeProgressView:function(){var e=this.options.appApi.statusMenuApi;this._progressView&&(this._progressView.close(),this._progressView=undefined),e.setStatus(n.HOME,{status:e.STATUS_IDLE}),e.hideStatusMenuItem(n.HOME)},_logEventTypeAndNames:function(e,t){return this.options.appApi.displayApi.isDebugLogging()&&LOG(e.type+this._getFileUploadEventSeparator(e)+this._getFileUploadFileNames(t)),undefined},_logProgressName:function(e,t){return undefined},_logProgress:function(e,t){return undefined},_getFileUploadFileNames:function(e){var t="";return _.each(e.files,function(e){t.length>0&&(t+=", "),t+=e.name}),t},_getFileUploadEventSeparator:function(e){var t="fileuploadprogressall",n="";return _.times(t.length-e.type.length,function(){n+=" "}),n+" : "},_getProgress:function(e){var t=e.total,n=0;return t>0&&(n=parseInt(e.loaded/t*100,10)),"loaded: "+e.loaded+" total: "+e.total+" "+n+"%"}})}),define("files/dev/ops/listening/listening-for-quota-errors-op",["core/ac-core","files/ac-files","core/ops/op"],function(e,t){t.ListeningForQuotaErrorsOp=e.Op.extend({run:function(){var e=$.Deferred();return this.options.appApi.errorApi.listenTo(this,"change:error",this._onErrorChange),this._deferred=e,this._deferred.resolve(),e.promise()},_onErrorChange:function(t,n){var r=this.options;if(!n)return;if(n.type!==e.ErrorUiModel.ERROR_TYPE_QUOTA)return;e.opFactory.create("ShowingQuotaWarningDlgOp",_.extend({},r,{uploading:!0,parentView:r.rootView})).run().then(function(){r.appApi.errorApi.dequeueError()})}})}),define("files/dev/ops/listening/listening-for-search-invalidation-op",["core/ac-core","files/ac-files","core/ops/while-signed-in-op"],function(e,t){t.ListeningForSearchInvalidationOp=e.WhileSignedInOp.extend({run:function(){var e=$.Deferred();return this.listenTo(this.options.searchUiModel,"change:invalid",this._onInvalidChange),this._deferred=e,e.promise()},_onInvalidChange:function(e,n){var r=this.options;n&&e.isSearching()&&r.appApi.routerApi.currentPathStartsWith("files")&&t.opFactory.create("SearchingOp",r).run()}})}),define("files/dev/ops/listening/listening-for-search-queries-change-op",["core/ac-core","files/ac-files","core/ops/while-signed-in-op"],function(e,t){return t.ListeningForSearchQueriesChangeOp=e.WhileSignedInOp.extend({run:function(){return this.listenTo(this.options.searchUiModel,"change:field_queries_request",this._onFieldQueriesRequestChange),$.Deferred().promise()},_onFieldQueriesRequestChange:function(){var e=this.options;if(e.searchUiModel.get("too_many_query_boxes"))return;e.selectionUiModel.clearSelection(),t.opFactory.create("SearchingIfAskedOp",e).run()}}),t.ListeningForSearchQueriesChangeOp}),define("files/dev/ops/listening/listening-for-selection-change-op",["core/ac-core","files/ac-files","core/utils/util","core/ops/while-signed-in-op"],function(e,t,n){t.ListeningForSelectionChangeOp=e.WhileSignedInOp.extend({run:function(){return this._addUiModelEventListeners(),this._addAppApiCallbacks(),$.Deferred().promise()},_addUiModelEventListeners:function(){this.listenTo(this.options.selectionUiModel,"change:selected_item_models",this._onLocalSelectedItemModelsChange)},_removeUiModelEventListeners:function(){this.stopListening()},_onLocalSelectedItemModelsChange:function(e,t){this._removeAppApiCallbacks(),this.options.appApi.selectionApi.setSelectedItemModels(t),this._addAppApiCallbacks()},_addAppApiCallbacks:function(){var e=this.options,t=e.appApi,r=e.isDesktopConnectorPlugin||!1;n.isCEF()&&!r&&t.sessionApi.addSignedInChangeCallback(this._onSignedInChange),t.selectionApi.addSelectedItemsModelsChangeCallback(this._onAppSelectedItemModelsChange)},_onSignedInChange:function(e,t){t||(this._removeAppApiCallbacks(),this._removeUiModelEventListeners())},_removeAppApiCallbacks:function(){this.options.appApi.selectionApi.removeSelectedItemsModelsChangeCallback(this._onAppSelectedItemModelsChange)},_onAppSelectedItemModelsChange:function(e,t){if(this.options.isInSearchResultsView&&e.isItemSelected())return;this._removeUiModelEventListeners(),this.options.selectionUiModel.clearSelection(),this._addUiModelEventListeners()}})}),define("files/dev/views/view-events",["files/ac-files"],function(e){return e.ViewEvents={NAVIGATE_TO_FOLDER:"files:navigate-to-folder",FILTER_MENU_BTN_CLICK:"files:filter-menu-button-click",NEW_FOLDER:"files:new-folder",NEW_FOLDER_DLG_CREATE:"files:new-folder-dlg-create",SORT_MENU_BTN_CLICK:"files:sort-menu-button-click",TAGS_BTN_CLICK:"files:tags-button-click",SEARCH_BTN_CLICK:"files:search-button-click",SELECT_FILTER_MENU_ITEM:"files:select-filter-menu-item",SHARE_ITEMS_FROM_DLG:"files:share-items-from-dlg",SHARE_ITEM:"files:share-item",FULL_PREVIEW_CLOSE:"files:full-preview-close",FULL_PREVIEW_MENU_BTN_CLICK:"files:full-preview-menu-btn-click",FULL_PREVIEW_DELETE:"files:full-preview-delete",FULL_PREVIEW_PLUGIN_CLICK:"files:full-preview-plugin-click"},e.ViewEvents}),define("files/dev/ops/listening/listening-for-view-events-op",["core/ac-core","files/ac-files","core/ops/while-signed-in-op","core/views/view-events","files/views/view-events"],function(e,t){t.ListeningForViewEventsOp=e.WhileSignedInOp.extend({initialize:function(){e.WhileSignedInOp.prototype.initialize.call(this),this._initEventMap()},run:function(){var e=$.Deferred();return this.listenTo(this.options.rootView,"all",this._onViewEvent),this._deferred=e,e.promise()},_onViewEvent:function(t,n){var r,i,s,o;r=this._eventMap[t],r&&(i=r[0].create(r[1],n));if(!i){t!==e.ViewEvents.MENU_CLOSED&&LOG(0,"AcFiles.ListeningForViewEventsOp._onViewEvent ignoring "+t);return}s=i.options,s&&(o=s.parentDeferred),i.run().then(function(){o&&o.resolve()},function(){o&&o.reject()})},_mapEvent:function(e,t,n,r,i){e[t]=[n,r,i]},_initEventMap:function(){var n,r,i,s,o,u;n=this._eventMap={},r=this._mapEvent,i=e.opFactory,s=t.opFactory,o=e.ViewEvents,u=t.ViewEvents,r(n,o.SELECT_ITEM,i,"SelectingCollectionItemOp"),r(n,o.CLEAR_SELECTION,i,"ClearingSelectionOp"),r(n,o.OPEN_COLLECTION_ITEM,s,"OpeningCollectionItemOp"),r(n,o.OPEN_SELECTED_COLLECTION_ITEMS,s,"OpeningSelectedCollectionItemsOp"),r(n,o.SAVEAS_SELECTED_COLLECTION_ITEMS,s,"SaveAsSelectedCollectionItemsOp"),r(n,o.DOWNLOAD,i,"DownloadingAssetIfExistsOp"),r(n,o.DOWNLOAD_ZIP,i,"DownloadingZipStartOp"),r(n,o.DELETE,i,"DeletingSelectionIfConfirmedOp"),r(n,o.RENAME,i,"ShowingRenameDlgOp"),r(n,o.MOVE,i,"ShowingMoveDlgOp"),r(n,o.RENAME_ITEM_FROM_DLG,i,"RenamingItemFromDlgOp"),r(n,o.SHOW_PUBLIC_SHARE_DLG,s,"ShowingPublicShareDlgOp"),r(n,u.SHARE_ITEMS_FROM_DLG,s,"SharingItemsFromDlgOp"),r(n,u.SHARE_ITEM_FROM_PANEL,s,"SharingItemFromPanelOp"),r(n,u.SHARE_ITEM,i,"SharingItemOp"),r(n,o.MOVE_DLG_MOVE,i,"MovingItemsOp"),r(n,o.DUP_DLG_DELETE_EXISTING,i,"DeletingExistingDupOp"),r(n,o.DUP_DLG_RENAME_ADDED,i,"RenamingAddedDupOp"),r(n,o.GET_FOLDER_ITEMS,i,"GettingFolderItemsOp"),r(n,o.COLLECTION_RENDER_BEGIN,i,"HandlingCollectionRenderBeginOp"),r(n,o.COLLECTION_RENDER_END,i,"HandlingCollectionRenderEndOp"),r(n,o.GET_HOVER_PREVIEW_METADATA,i,"GettingHoverPreviewMetadataOp"),r(n,o.GET_RHP_PREVIEW_METADATA,i,"GettingRhpPreviewMetadataOp"),r(n,o.GET_RHP_FOLDER_CHILD_COUNTS,i,"GettingRhpFolderChildCountsOp"),r(n,o.SHOW_QUOTA_WARNING_DLG,i,"ShowingQuotaWarningDlgOp"),r(n,u.NAVIGATE_TO_FOLDER,s,"NavigatingToFolderOp"),r(n,o.SEARCH_IN_FOLDER,s,"SearchingOp"),r(n,u.NEW_FOLDER,s,"ShowingNewFolderDlgOp"),r(n,u.NEW_FOLDER_DLG_CREATE,s,"CreatingFolderFromDlgOp"),r(n,o.ADD_SEARCH_FIELD_QUERY,s,"AddingSearchFieldQueryOp"),r(n,o.REMOVE_SEARCH_FIELD_QUERY,s,"RemovingSearchFieldQueryOp"),r(n,o.REMOVE_LAST_FIELD_QUERY,s,"RemovingLastFieldQueryOp"),r(n,o.REMOVE_TYPE_FIELD_QUERY,s,"RemovingTypeFieldQueryOp"),r(n,o.REMOVE_TIME_FIELD_QUERY,s,"RemovingTimeFieldQueryOp"),r(n,o.REMOVE_NAME_FIELD_QUERY,s,"RemovingNameFieldQueryOp"),r(n,o.REMOVE_REMOVABLE_QUERIES,s,"RemovingRemovableQueriesOp"),r(n,u.FILTER_MENU_BTN_CLICK,s,"TogglingFilterMenuOp"),r(n,u.SORT_MENU_BTN_CLICK,s,"TogglingSortMenuOp"),r(n,o.VIEW_BY,s,"ChangingCollectionViewOp"),r(n,o.SORT,s,"SortingCollectionOp"),r(n,u.FULL_PREVIEW_PLUGIN_CLICK,s,"SelectingFullPreviewPluginOp"),r(n,u.FULL_PREVIEW_MENU_BTN_CLICK,s,"TogglingFullPreviewActionMenuOp"),r(n,u.FULL_PREVIEW_DELETE,s,"DeletingFullPreviewItemIfConfirmedOp"),r(n,o.SELECTION_ACTION_ITEM_CLICK,i,"SelectingSelectionActionItemOp"),r(n,o.LAUNCH_FOOTER_URL_IN_BROWSER,i,"LaunchFooterUrlInBrowserOp"),r(n,o.SELECTION_ACTION_SEND_AND_TRACK,i,"SelectionActionLaunchSendAndTrackAppOp"),r(n,o.SELECTION_ACTION_ATTACH_TO_EMAIL,i,"SelectionActionAttachToEmailOp"),r(n,o.SHOW_CUSTOM_RANGE_DIALOG,i,"ShowCustomRangeDialogOp"),r(n,o.CONTEXT_BOARD_PRIMARY_TOOLS_CLICK,i,"ContextBoardPrimaryToolsClickAppOp"),r(n,o.CONTEXT_BOARD_PRIMARY_TOOLS_CLICK_REDUCEDMODE,i,"ContextBoardPrimaryToolsClickReducedModeAppOp"),r(n,o.F6_KEY_PRESSED,i,"F6KeyPressHandlerOp")}})}),define("files/dev/ops/manipulation/deleting-full-preview-item-if-confirmed-op",["core/ac-core","files/ac-files","i18n!core/nls/ui-strings","core/utils/util","core/utils/sc-analytics","core/ops/op"],function(e,t,n,r,i){t.DeletingFullPreviewItemIfConfirmedOp=e.Op.extend({run:function(){var t=this.options,s,o=t.appApi.dialogApi,u=[],a=this._logSiteCatalystEvent;return a(i.SHOWN),s=n.CONFIRM_DELETE_TITLE,u=r.addToArray(u,t.scContext),u=r.addToArray(u,this._getSiteCatalystContext()),o.displayTextAlert(o.SEVERITY_WARNING,s,n.CONFIRM_DELETE_MSG_ONE_ITEM,n.DELETE,n.CANCEL,{scContext:u}).then(function(){return t=_.extend({},t,{noScEvent:!0}),$.when(t.appApi.previewApi.closeFullPreview(),e.opFactory.create("DeletingItemOp",t).run().done(function(){a(i.SUCCESS),t.selectionUiModel.clearSelection()}))},function(){a(i.CANCEL)})},_getSiteCatalystContext:function(){return i.DELETE_DLG}})}),define("files/dev/ops/misc/changing-collection-view-op",["core/ac-core","files/ac-files","core/ops/op"],function(e,t){return t.ChangingCollectionViewOp=e.Op.extend({run:function(){var e=this.options;return e.collectionsUiModel.set("view",e.view),t.opFactory.create("SavingFilesPrefsOp",e).run(),this._getResolvedPromise()}}),t.ChangingCollectionViewOp}),define("files/dev/ops/misc/navigating-to-folder-op",["core/ac-core","files/ac-files","core/utils/util","core/ops/op"],function(e,t,n){t.NavigatingToFolderOp=e.Op.extend({run:function(r,i){var s=this.options,o=s.appApi,u=o.folderApi,a=o.displayApi,f=s.collectionUiModel,l,c=s.noUrlUpdate,h=s.noHistoryEffect,p=o.routerApi,d=o.saveAsApi,v=new $.Deferred,m=[],g;return n.isCEF()&&s.folderModel.get("content_type")&&s.folderModel.get("content_type")!=="application/vnd.adobe.skybox.folder"?(a.showSpinner(!0),o.saveAsApi.isRunningInFileSaveAs()&&o.saveAsApi.setCanSave(!1),s.selectionUiModel.clearSelection(),s.folderModel.fetch(s).done(function(){o.saveAsApi.isRunningInFileSaveAs()&&o.saveAsApi.setCanSave(!0),a.showSpinner(!1),s.folderModel.trigger("change:object_type"),v.resolve()}).fail(function(){a.showSpinner(!1),v.reject()}),v.promise()):(r=r||s.id,r?(a.showSpinner(!0),l="folder/"+encodeURIComponent(r),!c&&!h&&!p.isCurrentPath(l)&&p.navigate(l),(c||r!==u.getCurrentFolderId(s.pluginId))&&s.selectionUiModel.clearSelection(),u.setCurrentFolderId(s.pluginId,r),n.isCEF()&&d.isRunningInFileSaveAs()&&(d.setCurrentFolderId(r),d.setCanSave(!1)),!_.isUndefined(i)&&!_.isUndefined(i.ignoreErrors)&&(m=i.ignoreErrors),e.opFactory.create("GettingFolderOp",_.extend({},s,{ignoreErrors:m})).run(r,i).then(function(){f&&f.clearItemUiModels(),n.isCEF()&&d.isRunningInFileSaveAs()&&d.setCanSave(!0),u.setFilesCollection(s.folderModel.get("items").models),a.showSpinner(!1)},function(e){g=_.find(m,function(e){return e===404}),e.status===404&&!_.isUndefined(g)&&t.opFactory.create("NavigatingToFolderOp",s).run(u.getRootFolderId(s.pluginId),{force:i.force}),a.showSpinner(!1)})):this._getRejectedPromise())}})}),define("files/dev/ops/misc/navigating-to-scan-folder-op",["core/ac-core","files/ac-files","core/utils/util","core/ops/op"],function(e,t,n){t.NavigatingToScanFolderOp=e.Op.extend({run:function(r,i){var s=this.options,o=s.appApi,u=o.folderApi,a=o.displayApi,f=s.collectionUiModel,l,c=s.pluginUiModel,h=s.noUrlUpdate,p=s.noHistoryEffect,d=o.routerApi,v=o.saveAsApi,m=new $.Deferred,g=[],y,b=!1,w="Adobe Scan",E,S=!1,x;r=s.appApi.folderApi.getRootFolderId();if(r===s.appApi.folderApi.getRootFolderId()){var T=s.folderModel.get("members");S=!0,_.each(T,function(e){if(e.object_type&&e.object_type==="folder"&&e.name.toLowerCase()===w.toLowerCase()){var t=s.appApi.folderApi.getRootFolderId(),n=e.parent_id;if(n===t||t.substring(t.lastIndexOf(":")+1)===n)r=e.id,b=!0,x=e.name}}),r===s.appApi.folderApi.getRootFolderId()&&S===!0&&b===!1?(E=!1,s.folderModel.scanFound=!1):r===s.appApi.folderApi.getRootFolderId()&&S===!0&&b===!0&&(E=!0,s.folderModel.scanFound=!0,s.folderModel.scanId=r,s.folderModel.scanFolderName=x)}return r!==s.appApi.folderApi.getRootFolderId()&&b===!0&&(E=!0,s.folderModel.scanFound=!0,s.folderModel.scanId=r,s.folderModel.scanFolderName=x),r?(a.showSpinner(!0),l="folder/"+encodeURIComponent(r),!h&&!p&&!d.isCurrentPath(l)&&d.navigate(l),(h||r!==u.getCurrentFolderId(s.pluginId))&&s.selectionUiModel.clearSelection(),u.setCurrentFolderId(s.pluginId,r),n.isCEF()&&v.isRunningInFileSaveAs()&&(v.setCurrentFolderId(r),v.setCanSave(!1)),!_.isUndefined(i)&&!_.isUndefined(i.ignoreErrors)&&(g=i.ignoreErrors),S===!0&&E===!1?e.opFactory.create("GettingFolderOp",_.extend({},s,{ignoreErrors:g})).run(r,i).then(function(){f&&f.clearItemUiModels(),n.isCEF()&&v.isRunningInFileSaveAs()&&v.setCanSave(!0),u.setFilesCollection(s.folderModel.get("items").models);var e=s.folderModel.get("members"),i=!1,o=!0;_.each(e,function(e){if(e.object_type&&e.object_type==="folder"&&e.name.toLowerCase()===w.toLowerCase()){var t=s.appApi.folderApi.getRootFolderId(),n=e.parent_id;if(n===t||t.substring(t.lastIndexOf(":")+1)===n)r=e.id,i=!0}}),S===!0&&i===!0?(s.folderModel.scanFound=!0,s.folderModel.scanId=r,t.opFactory.create("NavigatingToScanFolderOp",s).run(u.getRootFolderId(s.pluginId),{force:s})):S===!0&&i===!1&&(s.folderModel.scanFound=!1),a.showSpinner(!1)},function(e){y=_.find(g,function(e){return e===404}),e.status===404&&!_.isUndefined(y)&&t.opFactory.create("NavigatingToScanFolderOp",s).run(u.getRootFolderId(s.pluginId),{force:i.force}),a.showSpinner(!1)}):b===!1?e.opFactory.create("GettingFolderOp",_.extend({},s,{ignoreErrors:g})).run(r,i).then(function(){f&&f.clearItemUiModels(),n.isCEF()&&v.isRunningInFileSaveAs()&&v.setCanSave(!0),u.setFilesCollection(s.folderModel.get("items").models),t.opFactory.create("NavigatingToScanFolderOp",s).run(u.getRootFolderId(s.pluginId),{force:s}),a.showSpinner(!1)},function(e){y=_.find(g,function(e){return e===404}),e.status===404&&!_.isUndefined(y)&&t.opFactory.create("NavigatingToScanFolderOp",s).run(u.getRootFolderId(s.pluginId),{force:i.force})}):e.opFactory.create("GettingFolderOp",_.extend({},s,{ignoreErrors:g})).run(r,i).then(function(){f&&f.clearItemUiModels(),n.isCEF()&&v.isRunningInFileSaveAs()&&v.setCanSave(!0),u.setFilesCollection(s.folderModel.get("items").models),s.appApi.siteCatalystApi.logScEvent(["ScanUser:FoldersShown:"+ +s.folderModel.getChildFoldersCount()],{featureType:"AdobeScanTab:Clicked",sectionName:"ScanPromotion"}),s.appApi.siteCatalystApi.logScEvent(["ScanUser:FilesShown:"+ +s.folderModel.getChildFilesCount()],{featureType:"AdobeScanTab:Clicked",sectionName:"ScanPromotion"}),a.showSpinner(!1)},function(e){y=_.find(g,function(e){return e===404}),e.status===404&&!_.isUndefined(y)&&t.opFactory.create("NavigatingToScanFolderOp",s).run(u.getRootFolderId(s.pluginId),{force:i.force}),a.showSpinner(!1)})):this._getRejectedPromise()}})}),define("files/dev/ops/misc/navigating-to-acroprefs-folder-op",["core/ac-core","files/ac-files","core/utils/util","core/ops/op"],function(e,t,n){t.NavigatingToAcroPrefsFolderOp=e.Op.extend({run:function(n,r){var i=this.options,s=[],o;i.folderModel.ScanInstalled=!1,s=[404];var u=i.appApi.folderApi.getAcroPrefsFolderId();return u?e.opFactory.create("GettingSystemFolderMetadataOp",_.extend({},i,{ignoreErrors:s})).run(u).then(function(e){var n=i.appApi.rnaApi,r=_.find(s,function(e){return e===404});e.status===404&&!_.isUndefined(r)&&t.opFactory.create("NavigatingToAcroPrefsFolderOp",i).run();if(e.members){var o=e.members;_.each(o,function(e){e.name==="ScanInstalled"&&(i.folderModel.ScanInstalled=!0)})}var u="NO";i.folderModel.ScanInstalled===!0&&(u="YES"),n.done(function(e){e.isFeatRunning()&&e.isASTestAllowInstantiation()&&e.invokeMethod({methodName:"logASTestReportAPI",methodArgs:["ScanTabData","ScanTabAcroprefs",u]})})}):$.Deferred().reject().promise()}})}),define("files/dev/ops/misc/opening-collection-item-op",["core/ac-core","files/ac-files","plugins-common/ac-plugins","core/utils/util","core/ops/op"],function(e,t,n,r){t.OpeningCollectionItemOp=e.Op.extend({run:function(){var e=this.options,i=e.appApi,s=e.itemModel,o=e.itemView,u,a,f,l=e.selectionUiModel;if(!o&&!s)return this._getRejectedPromise();o?u=o.model:u=s,a=u.id;if(u.isFolder()&&(o||r.isCEF()&&!(l.getNumSelectedItems()>1)))f=t.opFactory.create("NavigatingToFolderOp",_.extend({},e.collectionItemsView?e.collectionItemsView.options:e,{id:a}));else{if(!i.acrobatApi.isInAcrobat())return e.noFullPreview||(e.notDeselectAll||e.selectionUiModel.deselectAllExcept(a,!0),u.isForm()?i.pluginsApi.selectPlugin(n.FILLSIGN,{formId:a,formName:u.get("name")}):r.isCEF()&&u.isPDF()?t.opFactory.create("OpeningFullPreviewOp",_.extend(e,{id:a,itemModel:u})).run():i.routerApi.navigate("file/"+encodeURIComponent(a),{trigger:!0})),this._getResolvedPromise();f=t.opFactory.create("OpeningInAcrobatOp",_.extend({},e,{ids:[a]}))}return f.run()}})}),define("files/dev/ops/misc/opening-selected-collection-items-op",["core/ac-core","files/ac-files","core/ops/op"],function(e,t){t.OpeningSelectedCollectionItemsOp=e.Op.extend({run:function(){var e=this.options,n,r,i=[];return n=e.selectionUiModel,r=n.get("selected_item_models"),_.each(r,function(n){var r=t.opFactory.create("OpeningCollectionItemOp",_.extend({},e,{itemModel:n,notDeselectAll:!0})).run();i.push(r)}),$.when.apply($,i)}})}),define("files/dev/ops/misc/save-as-selected-collection-items-op",["core/ac-core","files/ac-files","i18n!core/nls/ui-strings","core/models/rna/rna-notification-model","core/ops/op"],function(e,t,n,r){var i="binder.zip";t.SaveAsSelectedCollectionItemsOp=e.Op.extend({run:function(){var t=this.options,n,s,o=t.appApi,u=$.Deferred().resolve().promise(),a,f,l,c,h={notificationHeading:t.notificationHeading};n=t.selectionUiModel,a=n.getSelectionCountByType(),f=a.numFiles,l=a.numFolders;if(l===0&&f>0){s=n.getSelectedItemModels(),s=_.filter(s,function(e){return!e.isForm()});if(s.length===0)return u;s.length===1?c=s[0].get("name"):c=i,h.fileName=c,h.fileExtn=e.Util.getExtension(c),h.showDownloadAll=!1,o.rnaApi.done(_.bind(function(e){e.notificationAPI.createNotification({operationType:r.NOTIFICATION_OPERATIONS.PROCESS,state:r.NOTIFICATION_STATES.IN_PROGRESS,userData:JSON.stringify(h),progress:0,description:t.notificatonCategory}).done(_.bind(function(t){s.length===1?this._downloadSingleFile(s[0],t).then(_.bind(function(e){this._onDownloadCompletion(t,e)},this),_.bind(function(e){this._onDownloadFailed(t,e)},this)):(e.rnaServicesAPI.showServicesProgressWidget(!0,!0,"busy",!0),this._downloadMultipleFiles(s,t).then(_.bind(function(e){this._onDownloadCompletion(t,e)},this),_.bind(function(e){this._onDownloadFailed(t,e)},this)))},this))},this))}return u},_downloadSingleFile:function(t,n){var i=this.options,s,o=e.opFactory;return s=o.create("DownloadingFileOp",_.extend({},i,{itemModelProxy:t._proxy,assetId:t.id,fileName:t.get("name")})).run(),s[1].done(function(e){var t=n.get("userData"),s={};try{s=JSON.parse(t)}catch(o){}e.errorSet?i.appApi.rnaApi.done(_.bind(function(e){e.notificationAPI.removeNotification(n.get("notificationID"))},this)):(e.downloadedFileName&&(s.downloadedFileName=e.downloadedFileName),n.invoke("setProperty",{userData:JSON.stringify(s),operationType:r.NOTIFICATION_OPERATIONS.DOWNLOAD}),i.appApi.rnaApi.done(_.bind(function(e){e.rnaServicesAPI.showServicesProgressWidget(!0,!0,"busy",!0)},this)))}),s[0]},_downloadMultipleFiles:function(t,n){var r=this.options,s=e.opFactory,o=_.pluck(t,"id").join(";");return s.create("DownloadingZipStartOp",_.extend({},r,{id_list:o,numForms:0,fileName:i,notificationObj:n})).run()},_onDownloadCompletion:function(e,t){var n=e.get("userData"),i={};try{i=JSON.parse(n)}catch(s){}t.downloadedFileSys&&(i.downloadedFileSys=t.downloadedFileSys),t.downloadedFilePath&&(i.downloadedFilePath=t.downloadedFilePath),e.invoke("setProperty",{operationType:"",userData:JSON.stringify(i),state:r.NOTIFICATION_STATES.DOWNLOADED})},_onDownloadFailed:function(e,t){if(t!==7){var i={errorTitle:n.NOTIFICATION_DOWNLOAD_ERROR,errorBody:"",downloadError:!0,showRetry:!1};e.invoke("setProperty",{operationType:"",state:r.NOTIFICATION_STATES.FAILED,error:JSON.stringify(i)})}}})}),define("files/dev/ops/misc/sorting-collection-op",["core/ac-core","files/ac-files","core/utils/sc-analytics","core/ops/op"],function(e,t,n){t.SortingCollectionOp=e.Op.extend({run:function(){var n=this.options,r=this.options.sortUiModel,i=n.orderBy,s=e.SortUiModel,o;r.setOrder(i,n.orderDirection),(i===s.ORDER_BY_DATE_ADDED||i===s.ORDER_BY_DATE_MODIFIED||i===s.ORDER_BY_DATE_LAST_ACCESS)&&r.set("mru_date_order",i),this.options.appApi.siteCatalystApi.logVirgoSortEvent(this.options.appApi.siteCatalystApi._getLogSubCategory(this.options.pluginId),this._getLogColumnName(i),n.orderDirection===s.ORDER_DESCENDING);if(n.isInSearchResultsView){var u=this.options.searchModel.get("items"),a=n.orderDirection===e.SortUiModel.ORDER_ASCENDING?1:-1,f,l;return i===e.SortUiModel.ORDER_BY_FILE_NAME?u.comparator=function(e,t){return f=e.get(i).toLowerCase(),l=t.get(i).toLowerCase(),f>l?1*a:ft.get(i)?1*a:e.get(i)1&&(a=t.get("name").toLowerCase(),o=d.$and[r][e.SearchUiModel.FIELD_ALL].toLowerCase(),o=o.slice(1,i-1),n=n||a.indexOf(o)>-1));return u?t.isPDF():n&&t.isPDF()})):w.reset(t.folderModel.get("items").filter(function(e){return e.isPDF()})),l.set("status",e.SearchUiModel.STATUS_SUCCEEDED),this._getResolvedPromise();if(l.showFolders(!0)){t.pluginId==="scan_files"?A={parent_id:t.search_folder_id||t.appApi.folderApi.getCurrentFolderId(a)||l.get("current_folder_id")}:A={parent_id:t.search_folder_id||l.get("current_folder_id")||t.appApi.folderApi.getCurrentFolderId(a)},O={object_type:"folder"},M={$and:[O,A]},d.$and||(H=d,d={},d.$and=[H]);for(P=0;Po+50?o+50:s.getSearchResultCount();if(oo+50?o+50:s.getSearchResultCount();if(o0&&r.set({status:t.SharingUiModel.STATUS_PENDING}),_.each(i,function(t){s={model:t,isPublic:o},a=e.opFactory.create("SharingItemOp",s).run(),a.fail(function(e){r.enqueueAjaxError(t,e)}),u.push(a)}),$.when.apply(null,u).done(function(){r.set({status:t.SharingUiModel.STATUS_SUCCEEDED})})}})}),define("files/dev/ops/user/restoring-files-prefs-op",["core/ac-core","files/ac-files","core/ops/op"],function(e,t){return t.RestoringFilesPrefsOp=e.Op.extend({run:function(){var e=this.options,t=e.sortUiModel,n,r,i,s,o,u,a,f=e.collectionsUiModel,l;if(e.noPreferences)return;return n=e.appApi.usersMeApi.getUserPrefsByCategory("files"),r=n[e.pluginId]||n,l=e.appApi.routerApi.getQueryParams(),i=r.sort,i&&!t.hasSortQueryParam(l)&&t.set({order_by:i.order_by,order_direction:i.order_direction,mru_date_order:i.mru_date_order}),s=r.collections,s&&!f.hasViewQueryParam(l)&&f.set("view",s.view),o=r.fullPreview,o&&(u=o.show_info,a=o.show_rhp,u&&!a&&(a=u),e.fullPreviewUiModel.set("show_rhp",a)),this._getResolvedPromise()}}),t.RestoringFilesPrefsOp}),define("files/dev/ops/user/saving-files-prefs-op",["core/ac-core","files/ac-files","core/ops/op"],function(e,t){return t.SavingFilesPrefsOp=e.Op.extend({run:function(){var e=this.options,t=e.appApi.usersMeApi,n=e.sortUiModel,r=e.collectionsUiModel,i=e.fullPreviewUiModel,s,o,u=this._getResolvedPromise();return e.noPreferences?u:(o={sort:{order_by:n.get("order_by"),order_direction:n.get("order_direction"),mru_date_order:n.get("mru_date_order")},collections:{view:r.get("view")},fullPreview:{show_rhp:i.get("show_rhp")}},s=t.getUserPrefsByCategory("files"),s[e.pluginId]=o,t.setUserPrefs("files",s))}}),t.SavingFilesPrefsOp}),define("files/dev/ops/op-factory",["core/ac-core","files/ac-files","files/ops/acrobat/initializing-acrobat-op","files/ops/acrobat/selecting-acrobat-filter-op","files/ops/creating/creating-folder-from-dlg-op","files/ops/dialogs/showing-new-folder-dlg-op","files/ops/listening/listening-for-current-folder-notifications-op","files/ops/listening/listening-for-dup-errors-op","files/ops/listening/listening-for-file-upload-events-op","files/ops/listening/listening-for-quota-errors-op","files/ops/listening/listening-for-search-invalidation-op","files/ops/listening/listening-for-search-queries-change-op","files/ops/listening/listening-for-selection-change-op","files/ops/listening/listening-for-view-events-op","files/ops/manipulation/deleting-full-preview-item-if-confirmed-op","files/ops/misc/changing-collection-view-op","files/ops/misc/navigating-to-folder-op","files/ops/misc/navigating-to-scan-folder-op","files/ops/misc/navigating-to-acroprefs-folder-op","files/ops/misc/opening-collection-item-op","files/ops/misc/opening-selected-collection-items-op","files/ops/misc/save-as-selected-collection-items-op","files/ops/misc/sorting-collection-op","files/ops/misc/toggling-filter-menu-op","files/ops/misc/toggling-sort-menu-op","files/ops/preview/closing-full-preview-op","files/ops/preview/creating-ngdoc-rendition-op","files/ops/preview/getting-full-preview-metadata-op","files/ops/preview/listening-for-ngdoc-job-status-op","files/ops/preview/loading-full-preview-plugins-op","files/ops/preview/opening-full-preview-op","files/ops/preview/selecting-full-preview-plugin-op","files/ops/preview/toggling-full-preview-action-menu-op","files/ops/searching/adding-search-field-query-op","files/ops/searching/closing-search-op","files/ops/searching/scan-closing-search-op","files/ops/searching/opening-search-op","files/ops/searching/removing-last-field-query-op","files/ops/searching/removing-time-field-query-op","files/ops/searching/removing-type-field-query-op","files/ops/searching/removing-name-field-query-op","files/ops/searching/removing-removable-queries-op","files/ops/searching/removing-search-field-query-op","files/ops/searching/searching-if-asked-op","files/ops/searching/scan-searching-if-asked-op","files/ops/searching/searching-op","files/ops/searching/uss-searching-op","files/ops/sharing/sharing-item-from-panel-op","files/ops/sharing/sharing-items-from-dlg-op","files/ops/user/restoring-files-prefs-op","files/ops/user/saving-files-prefs-op","core/ops/dialogs/show-custom-range-dlg-op"],function(e,t){t.OpFactory=e.Op.extend({create:function(e,n){var r=t[e];if(!!r)return new r(n);LOG(0,"AcFiles.OpFactory.create: Unrecognized class: "+e)}})}),define("files/dev/ac-files-init",["files/ac-files","files/models/model-factory","files/models/ui/ui-model-factory","files/ops/op-factory"],function(e){return _.extend(e,{modelFactory:new e.ModelFactory,uiModelFactory:new e.UiModelFactory,opFactory:new e.OpFactory}),e}),define("files/dev/templates/files-header-template",[],function(){return'
<%= fileHeaderLabel %>
<%= fileHeaderCount %>
'}),define("files/dev/templates/filter-menu-template",[],function(){return'
<%= filterBy %>
'}),define("files/dev/templates/filter-added-by-menu-template",[],function(){return''}),define("files/dev/views/filter-submenu-view",["core/ac-core","files/ac-files","core/utils/util","core/utils/css-util","core/utils/view-util","core/utils/truncate","core/views/menu-view"],function(e,t,n,r,i,s){return t.FilterSubmenuView=e.MenuView.extend({events:function(){return _.extend({},e.MenuView.prototype.events,{"click .files-filter-menu-submenu-item":"_onMenuItemClick","focusin .files-filter-menu-submenu-item":"_onMenuFocusInHC","focusout .files-filter-menu-submenu-item":"_onMenuFocusOutHC"})},render:function(){var t=this.$el,n=this.options.$menuBtn,i,s;return e.MenuView.prototype.render.call(this),i=n.position(),s=n.height()+r.getExtraHeight(n),t.css("top",i.top+s+"px"),t.css("left",i.left+"px"),t.css("margin-top","8px"),t.width(n.width()+r.getPaddingWidth(n)),this},initialize:function(){},open:function(t,n){var r=this.options,i=r.animate,s;return r.animate=!n,s=e.MenuView.prototype.open.call(this,_.bind(function(){this._truncateMenuItems(),t&&t()},this)),r.animate=i,s},_truncateMenuItems:function(){var e=this.$el,t,n,o;t=e.find(".files-filter-menu-submenu-item"),t.each(_.bind(function(t,u){n=$(u),o=this._menuItemWidth,o||(o=n.parent().width()-r.getExtraWidth(n),i.isVerticalScrollBarPresent(e)&&(o-=i.getScrollBarWidth(e)),this._menuItemWidth=o),n.width(o),s.truncateElementText(n)},this))},_onMenuItemClick:function(e){var n=$(e.target);this.close(),this._triggerViewEvent(t.ViewEvents.SELECT_FILTER_MENU_ITEM,{filterMenuType:this.$el.attr("data-data"),filterMenuItemValue:n.attr("data-data"),filterMenuItemFilter:n.attr("data-worker"),filterMenuItemSiteCatalyst:n.attr("data-site-catalyst"),filterMenuItemQueryLabel:$.trim(n.text()),filterMenuItemQueryTitle:$.trim(n.attr("title"))})},_onMenuFocusInHC:function(e){var t=$(e.target);r.addClass(t,"theme-selectable")},_onMenuFocusOutHC:function(e){var t=$(e.target);r.removeClass(t,"theme-selectable")}}),t.FilterSubmenuView}),define("files/dev/views/filter-added-by-menu-view",["files/ac-files","files/templates/filter-added-by-menu-template","i18n!files/nls/ui-strings","files/views/filter-submenu-view"],function(e,t,n){return e.FilterAddedByMenuView=e.FilterSubmenuView.extend({render:function(){var r=this.$el;return e.FilterSubmenuView.prototype.render.call(this),r.children().length===0&&(r.html(_.template(t)({exportFromPdf:n.EXPORT_FROM_PDF,convertToPdf:n.CONVERT_TO_PDF,combineToPdf:n.COMBINE_TO_PDF,fillSign:n.FILL_SIGN,adobeAcrobat:n.ADOBE_ACROBAT,adobeReaderMobile:n.ADOBE_READER_MOBILE,adobeReader:n.ADOBE_READER})),this._initWrappers()),this}}),e.FilterAddedByMenuView}),define("files/dev/templates/filter-attr-menu-template",[],function(){return''}),define("files/dev/views/filter-attr-menu-view",["files/ac-files","files/templates/filter-attr-menu-template","i18n!core/nls/ui-strings","files/views/filter-submenu-view"],function(e,t,n){return e.FilterAttrMenuView=e.FilterSubmenuView.extend({render:function(){var r=this.$el;return e.FilterSubmenuView.prototype.render.call(this),r.children().length===0&&r.html(_.template(t)({fileName:n.FILE_NAME_CONTAINS,fileType:n.FILE_TYPE_IS,dateLastModified:n.DATE_LAST_MODIFIED,dateAdded:n.DATE_ADDED,dateAccessed:n.DATE_LAST_VIEWED,fileAddedBy:n.FILE_ADDED_BY})),this}}),e.FilterAttrMenuView}),define("files/dev/templates/filter-date-menu-template",[],function(){return''}),define("files/dev/views/filter-date-menu-view",["files/ac-files","files/templates/filter-date-menu-template","i18n!core/nls/ui-strings","files/views/filter-submenu-view"],function(e,t,n){return e.FilterDateMenuView=e.FilterSubmenuView.extend({render:function(){var r=this.$el;return e.FilterSubmenuView.prototype.render.call(this),r.children().length===0&&r.html(_.template(t)({custom:n.CUSTOM,today:n.TODAY,yesterday:n.YESTERDAY,withinLastWeek:n.WITHIN_LAST_WEEK,withinLastMonth:n.WITHIN_LAST_MONTH,oneToTwoMonthsAgo:n.ONE_TO_TWO_MONTHS_AGO,twoToThreeMonthsAgo:n.TWO_TO_THREE_MONTHS_AGO,threeToFourMonthsAgo:n.THREE_TO_FOUR_MONTHS_AGO,fourToFiveMonthsAgo:n.FOUR_TO_FIVE_MONTHS_AGO,fiveToSixMonthsAgo:n.FIVE_TO_SIX_MONTHS_AGO,sixToTwelveMonthsAgo:n.SIX_TO_TWELVE_MONTHS_AGO,moreThanOneYearAgo:n.MORE_THAN_ONE_YEAR_AGO})),this}}),e.FilterDateMenuView}),define("files/dev/templates/filter-file-type-menu-template",[],function(){return''}),define("files/dev/views/filter-file-type-menu-view",["files/ac-files","files/templates/filter-file-type-menu-template","i18n!core/nls/ui-strings","core/utils/file-types","files/views/filter-submenu-view"],function(e,t,n,r){return e.FilterFileTypeMenuView=e.FilterSubmenuView.extend({render:function(){var i=this.$el,s=r.MimeType,o=r.UiName;return e.FilterSubmenuView.prototype.render.call(this),i.children().length===0&&i.html(_.template(t)({fillsignMimeType:s.ADOBE_FILL_SIGN,fillsignUiName:o.ADOBE_FILL_SIGN,illustratorMimeType:s.ADOBE_ILLUSTRATOR,illustratorUiName:o.ADOBE_ILLUSTRATOR,indesignMimeType:s.ADOBE_INDESIGN,indesignUiName:o.ADOBE_INDESIGN,pdfMimeType:s.ADOBE_PDF,pdfUiName:o.ADOBE_PDF,photoshopMimeType:s.ADOBE_PHOTOSHOP,photoshopUiName:o.ADOBE_PHOTOSHOP,htmlMimeType:s.HTML,htmlUiName:o.HTML,imageMimeType:s.IMAGE,imageUiName:n.IMAGE,excelMimeType:s.MS_EXCEL,excelUiName:o.MS_EXCEL,powerpointMimeType:s.MS_POWERPOINT,powerpointUiName:o.MS_POWERPOINT,wordMimeType:s.MS_WORD,wordUiName:o.MS_WORD,textMimeType:s.TEXT,textUiName:n.TEXT,videoMimeType:s.VIDEO,videoUiName:n.VIDEO,zipMimeType:s.ZIP,zipUiName:o.ZIP})),this}}),e.FilterFileTypeMenuView}),define("files/dev/views/filter-menu-view",["core/ac-core","files/ac-files","files/templates/filter-menu-template","i18n!core/nls/ui-strings","i18n!files/nls/ui-strings","core/utils/css-util","core/utils/sc-analytics","core/views/menu-view","core/views/input-search-view","files/views/filter-added-by-menu-view","files/views/filter-attr-menu-view","files/views/filter-date-menu-view","files/views/filter-file-type-menu-view"],function(e,t,n,r,i,s,o){return t.FilterMenuView=e.MenuView.extend({events:function(){return _.extend({},e.MenuView.prototype.events,{"click .files-filter-menu-attr-menu-btn":"_onAttrMenuBtnClick","click .files-filter-menu-value-menu-btn":"_onValueMenuBtnClick"})},initialize:function(){e.MenuView.prototype.initialize.call(this)},render:function(){var t=this.$el,r=this.options;return e.MenuView.prototype.render.call(this),t.children().length===0&&(t.html(_.template(n)({filterBy:i.FILTER_BY,selectAttribute:i.SELECT_ATTRIBUTE,selectValue:i.SELECT_VALUE,enterValue:i.ENTER_VALUE,viewId:r.viewId})),this._initWrappers()),this.$attrMenuBtnLabel.text(i.SELECT_ATTRIBUTE),this.$valueMenuBtnLabel.text(i.SELECT_VALUE),this.$attrMenuBtn.removeClass("selected").removeAttr("aria-expanded"),this.$valueMenuBtn.removeClass("selected").removeAttr("aria-expanded").addClass("disabled").attr({"aria-disabled":"true",disabled:"disabled"}),r.searchUiModel.get("is_locked")&&this.$filterSubmenuBtns.addClass("disabled"),this._renderChildViews(),this},open:function(t){return this.options.noUrlUpdate?this._logSiteCatalystEvent([o.FILTER,o.SHOWN]):this._logSiteCatalystEvent(o.SHOWN),e.MenuView.prototype.open.call(this,_.bind(function(){this._sizeInputField(),this._renderChildViews(),this._openMenuView(this.$attrMenuBtn,this._attrMenuView,t,!0)},this))},close:function(t){var n=this.$valueField;e.MenuView.prototype.close.call(this,t),n.val()&&this._fileNameContainsView.commitText()},_onBodyClick:function(t){$(t.target).hasClass("clear-btn")&&this.$valueField.val(""),e.MenuView.prototype._onBodyClick.call(this,t)},_initWrappers:function(){e.MenuView.prototype._initWrappers.call(this),this.$attrMenuBtn=this.$(".files-filter-menu-attr-menu-btn"),this.$attrMenuBtnLabel=this.$(".files-filter-menu-attr-menu-btn-label"),this.$valueMenuBtn=this.$(".files-filter-menu-value-menu-btn"),this.$valueMenuBtnLabel=this.$(".files-filter-menu-value-menu-btn-label"),this.$valueField=this.$(".files-filter-menu-value-field"),this.$attrMenu=this.$(".files-filter-menu-attr-menu"),this.$fileAddedByAttr=this.$(".files-filter-menu-attr-menu-item.file-added-by"),this.$fileTypeMenu=this.$(".files-filter-menu-file-type-menu"),this.$fileAddedByMenu=this.$(".files-filter-menu-file-added-by-menu"),this.$dateMenu=this.$(".files-filter-menu-date-menu"),this.$filterSubmenuBtns=this.$(".files-filter-menu-submenu-btn")},_sizeInputField:function(){var e=this.$valueField,t=this.$attrMenuBtn;e.width(s.getFullWidth(t)-s.getExtraWidth(e)),e.height(t.height())},_renderChildViews:function(){return this.removeAllChildViews(),this._renderChildView("_attrMenuView",t.FilterAttrMenuView,this.$attrMenu,{$menuBtn:this.$attrMenuBtn,triggerEl:this.$attrMenuBtn.get(0)}),this._renderChildView("_fileNameContainsView",e.InputSearchView,this.$valueField,{searchField:e.SearchUiModel.FIELD_FILE_NAME}),this._renderChildView("_fileTypeMenuView",t.FilterFileTypeMenuView,this.$fileTypeMenu,{$menuBtn:this.$valueMenuBtn,triggerEl:this.$valueMenuBtn.get(0)}),this._renderChildView("_dateMenuView",t.FilterDateMenuView,this.$dateMenu,{$menuBtn:this.$valueMenuBtn,triggerEl:this.$valueMenuBtn.get(0)}),this._renderChildView("_addedByMenuView",t.FilterAddedByMenuView,this.$fileAddedByMenu,{$menuBtn:this.$valueMenuBtn,triggerEl:this.$valueMenuBtn.get(0)}),this},_getMenuButtonDownArrow:function(e){return e.find(".files-filter-menu-btn-down-arrow")},_openMenuView:function(e,t,n,r){this.options.searchUiModel.get("is_locked")||(e.addClass("selected").attr("aria-expanded","true"),t.open(n,r))},_toggleMenuView:function(e,t){if(this.options.searchUiModel.get("is_locked")||!t){e.removeClass("selected").removeAttr("aria-expanded");return}var n=t.isMenuOpen();e.toggleClass("selected",!n),n?(e.removeClass("selected").removeAttr("aria-expanded"),t.close()):(e.addClass("selected").attr("aria-expanded","true"),t.open().always(function(){e.removeClass("selected").removeAttr("aria-expanded")}))},_getSiteCatalystContext:function(){return this.options.noUrlUpdate?undefined:[o.SEARCH_BAR,o.FILTER]},_onViewEvent:function(n,r){var i,s,u,a,f=e.SearchUiModel;n===t.ViewEvents.SELECT_FILTER_MENU_ITEM?(i={value:r.filterMenuItemValue,filter:r.filterMenuItemFilter,siteCatalyst:r.filterMenuItemSiteCatalyst,queryLabel:r.filterMenuItemQueryLabel},r.filterMenuType==="attribute"?this._onSelectAttrMenuItem(i):this._onSelectValueMenuItem(i)):(n===e.ViewEvents.ADD_SEARCH_FIELD_QUERY&&(u=this.$attrMenuBtn.data("data"),s=r.searchFieldQuery,s.commitQueryBox&&(this.close(),a=[],u===f.FIELD_FILE_NAME&&a.push(o.NAME),a.push(o.ENTERED),this._logSiteCatalystEvent(a)),s.queryLabel=r.searchUiModel.getFieldQueryLabel(s)),this.trigger(n,r))},_onSelectAttrMenuItem:function(t){var n=this.$attrMenuBtn,r=this.$attrMenuBtnLabel,s=this.$valueMenuBtn,o=this.$valueMenuBtnLabel,u=this.$valueField,a=t.value,f=e.SearchUiModel,l;n.data("data",a),r.text(t.queryLabel),s.removeClass("disabled").removeAttr("aria-disabled disabled"),s.show(),u.hide(),delete this._valueMenuView;switch(a){case f.FIELD_FILE_NAME:s.hide(),u.show(),l=this.options.menusUiModel.get("focus_delay"),_.delay(_.bind(function(){u.focus()},this),l);break;case f.FIELD_FILE_TYPE:this._openMenuView(s,this._fileTypeMenuView),this._valueMenuView=this._fileTypeMenuView,o.text(i.SELECT_FORMAT);break;case f.FIELD_FILE_ADDED_BY:this._openMenuView(s,this._addedByMenuView),this._valueMenuView=this._addedByMenuView,o.text(i.SELECT_TOOL);break;case f.FIELD_DATE_ADDED:case f.FIELD_DATE_MODIFIED:case f.FIELD_DATE_LAST_ACCESS:this._openMenuView(s,this._dateMenuView),this._valueMenuView=this._dateMenuView,o.text(i.SELECT_DATES)}this._logSiteCatalystEvent(t.siteCatalyst)},_onSelectValueMenuItem:function(t){var n=this.$attrMenuBtn,i,s,u,a=e.SearchUiModel,f;s=n.data("data"),u=[];switch(s){case a.FIELD_FILE_TYPE:f=o.FILE_TYPE;break;case a.FIELD_DATE_MODIFIED:f=o.DATE_MODIFIED;break;case a.FIELD_DATE_ADDED:f=o.DATE_ADDED;break;case a.FIELD_FILE_ADDED_BY:f=o.CREATED_BY_TOOL}u.push(f),u.push(t.siteCatalyst),this._logSiteCatalystEvent(u);var l=n.data("data-data");if(t.value=="custom"){var c=this.options,h=0;this._triggerViewEvent(e.ViewEvents.SHOW_CUSTOM_RANGE_DIALOG,{parentView:this.options.parentView,scContext:this._getParentScContext(),searchFieldQuery:{field:s,value:t.value,filter:t.filter,commitQueryBox:!0,queryLabel:i}})}else i=_.template(r.FILTER_DISPLAY_VALUE,{field:$.trim(n.text()),value:t.queryLabel}),this._triggerViewEvent(e.ViewEvents.ADD_SEARCH_FIELD_QUERY,{searchFieldQuery:{field:s,value:t.value,filter:t.filter,commitQueryBox:!0,queryLabel:i}});this.close()},_isClickOutsideMenu:function(){return!1},_onAttrMenuBtnClick:function(){var e=this.$attrMenuBtn,t=this.$valueMenuBtn,n=_.bind(function(){this.$valueMenuBtnLabel.text(i.SELECT_VALUE),t.removeData("data"),this._toggleMenuView(e,this._attrMenuView)},this);this._valueMenuView?this._valueMenuView.close(n):n()},_onValueMenuBtnClick:function(){var e=this.$valueMenuBtn;if(e.hasClass("disabled"))return!1;this._toggleMenuView(e,this._valueMenuView)},_onKeyDown:function(t){var n=t.target,r=!1;this.$attrMenuBtn.is(n)&&(r=this._onAttrMenuBtnKeyDown(t)),this.$valueMenuBtn.is(n)&&(r=this._onValueMenuBtnKeyDown(t));if(r)return r;e.MenuView.prototype._onKeyDown.apply(this,[t])},_onMenuBtnKeyDown:function(e,t){var n=e.which,r=$(e.target);switch(n){case 32:case 38:case 40:this._consumeEvent(e);if(n===38&&t||n===40&&!t||n===32)return r.click(),!0}return!1},_onAttrMenuBtnKeyDown:function(e){return this._onMenuBtnKeyDown(e,this._attrMenuView.isMenuOpen())},_onValueMenuBtnKeyDown:function(e){return this._onMenuBtnKeyDown(e,this._valueMenuView.isMenuOpen())}}),t.FilterMenuView}),define("files/dev/templates/sort-menu-template",[],function(){return'
<%= viewBy %>
<%= sortBy %>
'}),define("files/dev/views/sort-menu-view",["core/ac-core","files/ac-files","files/templates/sort-menu-template","i18n!files/nls/ui-strings","core/utils/sc-analytics","core/utils/css-util","core/utils/util","core/views/menu-view"],function(e,t,n,r,i,s,o){var u={};return t.SortMenuView=e.MenuView.extend({events:function(){return _.extend({},e.MenuView.prototype.events,{"click .files-sort-menu-item":"_onMenuItemClick","focusin .files-sort-menu-item":"_onMenuFocusInHC","focusout .files-sort-menu-item":"_onMenuFocusOutHC"})},initialize:function(){var t=e.SortUiModel;e.MenuView.prototype.initialize.call(this),u[t.ORDER_BY_FILE_NAME]=[i.FILE_NAME_UP,i.FILE_NAME_DOWN],u[t.ORDER_BY_FILE_TYPE]=[i.FILE_TYPE_UP,i.FILE_TYPE_DOWN],u[t.ORDER_BY_FILE_SIZE]=[i.FILE_SIZE_UP,i.FILE_SIZE_DOWN],u[t.ORDER_BY_DATE_ADDED]=[i.DATE_ADDED_UP,i.DATE_ADDED_DOWN],u[t.ORDER_BY_DATE_MODIFIED]=[i.DATE_MODIFIED_UP,i.DATE_MODIFIED_DOWN],u[t.ORDER_BY_DATE_LAST_ACCESS]=[i.DATE_ACCESSSED_UP,i.DATE_ACCESSED_DOWN]},render:function(){e.MenuView.prototype.render.call(this),this.$el.children().length===0&&(this.$el.html(_.template(n)({viewBy:r.VIEW_BY,list:r.LIST,thumbnail:r.THUMBNAIL,sortBy:r.SORT_BY,sortByFileName:r.SORT_BY_FILE_NAME,sortByFileType:r.SORT_BY_FILE_TYPE,sortBySize:r.SORT_BY_FILE_SIZE,sortByDateAdded:r.SORT_BY_DATE_ADDED,sortByDateModified:r.SORT_BY_DATE_MODIFIED,sortByDateAccessed:r.SORT_BY_DATE_VIEWED,viewId:this.options.viewId})),this._initWrappers()),this._showCurrentView(),this._showCurrentSort(),this.options.appApi.selectionApi.isRunningInFileSelection()||o.isCEF()&&this.options.appApi.saveAsApi.isRunningInFileSaveAs()||(this.$viewGroupOne.css("display","none"),this.$sortSeperator.css("display","none"),this.$sectionHeader.addClass("virgo-section-header"))},open:function(t){return this._logSiteCatalystEvent([i.SORT,i.SHOWN]),e.MenuView.prototype.open.call(this,t)},_initWrappers:function(){e.MenuView.prototype._initWrappers.call(this),this.$viewMenuItems=this.$(".files-sort-menu-item[data-section='view-by']"),this.$sortMenuItems=this.$(".files-sort-menu-item[data-section='sort-by']"),this.$sortMenuItemOrderIcons=this.$(".files-sort-menu-item-order-icon"),this.$fileInfoMenuItem=this.$(".files-sort-menu-item[data-value='file-info']"),this.$viewGroupOne=this.$(".viewGroupOne"),this.$sortSeperator=this.$(".sortSeperator"),this.$sectionHeader=this.$(".files-sort-menu-item-common")},_showCurrentView:function(){var e=this.options.collectionsUiModel,t;this.$viewMenuItems.removeClass("selected").attr("aria-checked","false"),t=this.$("[data-value="+e.get("view")+"]"),t.addClass("selected").attr("aria-checked","true")},_showCurrentSort:function(){var e=this.options.sortUiModel,t,n;e.get("is_locked")&&this.$sortMenuItems.addClass("disabled").attr({disabled:"disabled","aria-disabled":"true"}),this.$sortMenuItems.removeClass("ascending descending").attr("aria-checked","false"),this.$sortMenuItemOrderIcons.removeAttr("aria-label"),t=this.$("[data-value="+e.get("order_by")+"]"),n=t.find(".files-sort-menu-item-order-icon"),e.isAscending()?(t.addClass("ascending").attr("aria-checked","true"),n.attr("aria-label",r.ASCENDING)):(t.addClass("descending").attr("aria-checked","true"),n.attr("aria-label",r.DESCENDING))},_onMenuItemClick:function(e){var t=$(e.currentTarget),n=t.attr("data-section"),r=t.attr("data-value");if(t.hasClass("disabled")){this.close();return}this.close(_.bind(function(){n==="view-by"?this._viewBy(r):n==="sort-by"&&this._sortBy(r)},this))},_viewBy:function(t){this._logSiteCatalystEvent([i.VIEW_BY,t==="list"?i.LIST:i.THUMB,i.CHECKED]),this._triggerViewEvent(e.ViewEvents.VIEW_BY,{view:t})},_sortBy:function(t){var n=this.options,r=n.sortUiModel,s,o,a,f;s=r.get("order_by"),a=e.SortUiModel.ORDER_ASCENDING,f=e.SortUiModel.ORDER_DESCENDING,t===s?r.isAscending()?o=f:o=a:o=r.getOrderDirection(t),this._logSiteCatalystEvent([i.SORT_BY,u[t][o===a?0:1]]),this._triggerViewEvent(e.ViewEvents.SORT,{orderBy:t,orderDirection:o})},_getSiteCatalystContext:function(){return this.options.noUrlUpdate?undefined:i.SEARCH_BAR},_onMenuFocusInHC:function(e){var t=$(e.currentTarget);s.addClass(t,"theme-selectable")},_onMenuFocusOutHC:function(e){var t=$(e.currentTarget);s.removeClass(t,"theme-selectable")}}),t.SortMenuView}),define("files/dev/views/files-header-view",["core/ac-core","files/ac-files","files/templates/files-header-template","i18n!files/nls/ui-strings","core/utils/util","core/utils/view-util","core/utils/css-util","core/utils/sc-analytics","core/views/view","core/views/search-control-view","files/views/filter-menu-view","files/views/sort-menu-view"],function(e,t,n,r,i,s,o,u){return t.FilesHeaderView=e.View.extend({events:{"click .files-filter-menu-btn":"_onFilterMenuBtnClick","click .files-upload-btn":"_onUploadClick","mousedown .files-upload-btn":"_onUploadMouseDown","click .files-new-folder-btn":"_onNewFolderClick","click .files-sort-menu-btn":"_onSortMenuBtnClick"},initialize:function(){e.View.prototype.initialize.call(this),this._addFocusEventListener(),this._addKeyEventListener(),this._addUiModelEventListeners()},render:function(){var t=this.options,s=this.$el,u,a,f=t.appApi.pluginsApi,l=t.pluginId;e.View.prototype.render.call(this);if(s.children().length===0){var c=f.getSelectorApi(l).getSelectorLabel();s.html(_.template(n)({fileHeaderLabel:c,fileHeaderCount:r.COUNT,sort:r.SORT,uploadFile:r.UPLOAD_FILE,newFolder:r.NEW_FOLDER,filter:r.FILTER,viewId:t.viewId,pluginSelectorId:f.getPluginSelectorId(l)})),this._initWrappers(),u=this.$upload,(i.isIpad()||i.isIphone())&&(!e.Features.isFeatureEnabled("ios_upload_ui")||i.isIosVersion(5)||i.isIosVersion(4))&&u.hide(),t.noUpload&&u.hide(),t.enableDragAndDrop&&u.width(0),t.noNewFolder&&this.$newFolder.hide(),t.noSearchControl?(this.$searchControl.hide(),this.$(".files-header-label").show()):(this.$searchControl.show(),this.$(".files-header-label").hide()),t.noFilter&&this.$filterMenuBtn.hide(),t.noSort&&this.$sortMenuBtn.hide()}if(t.searchModel&&t.noSearchControl){var h=this.options.searchModel.get("total_hits");if(!_.isUndefined(h)){var p=_.template(r.COUNT,{count:h});this.$itemCount.text(p),this.$itemCount.show()}else this.$itemCount.hide()}return _.defer(_.bind(function(){a=this.$searchControl,a.width(Math.floor(s.width()-o.getFullWidth(this.$btnsRight))),this._renderChildViews(),this._positionFilterMenu(),s.height(o.getFullHeight(a))},this)),this},_initWrappers:function(){this.$searchControl=this.$(".search-control"),this.$itemCount=this.$(".files-header-count"),this.$btnsRight=this.$(".files-header-btns.right"),this.$filterMenuBtn=this.$(".files-filter-menu-btn"),this.$filterMenu=this.$(".files-filter-menu"),this.$newFolder=this.$(".files-new-folder-btn"),this.$upload=this.$(".files-upload-btn"),this.$uploadInput=this.$("input:file.file"),this.$sortMenuBtn=this.$(".files-sort-menu-btn"),this.$sortMenu=this.$(".files-sort-menu")},_showHeaderBtnClickedEffect:function(e,t){s.showClickedEffect(e,"files-header-btn-active","files-header-btn-transition",t)},_renderChildViews:function(){this.options.isInSearchResultsView||this._renderSearchControlView(),this._renderFilterMenuView(),this._renderSortMenuView()},_renderSearchControlView:function(){this._renderChildView("_searchControlView",e.SearchControlView,this.$searchControl)},_renderFilterMenuView:function(){this._renderChildView("_filterMenuView",t.FilterMenuView,this.$filterMenu,{parentView:this})},_renderSortMenuView:function(){this._renderChildView("_sortMenuView",t.SortMenuView,this.$sortMenu)},_positionFilterMenu:function(){var e=this.$filterMenuBtn,t=e.position();if(!t)return;this._filterMenuView.$el.css("right",this.$el.width()-t.left-o.getFullWidth(e)+1+"px")},_updateUploadButtonFocusStyle:function(e){var t=this.$("input:file");!e&&t.is(document.activeElement)?t.addClass("focused"):t.removeClass("focused"),i.isIE8()&&s.detachAndReattachElement(t.next())},_onFocusIn:function(){this._updateUploadButtonFocusStyle()},_onFocusOut:function(){this._updateUploadButtonFocusStyle(!0)},_onKeyDown:function(e){var t=$(e.target),n=!1;return this._updateUploadButtonFocusStyle(),s.descendantHasFocus(this.$el)?(t.is(this.$filterMenuBtn)&&(n=this._onFilterMenuBtnKeyDown(e)),t.is(this.$sortMenuBtn)&&(n=this._onSortMenuBtnKeyDown(e)),!n&&(t.is(".files-header-btn")||t.is(this.$("input:file")))&&(n=this._onFilesHeaderBtnKeyDown(e)),n):!1},_onFilterMenuBtnClick:function(){this.options.noUrlUpdate?this._logSiteCatalystEvent([u.FILTER_ICON,u.CLICKED]):this._logSiteCatalystEvent([u.SEARCH_BAR,u.FILTER_ICON,u.CLICKED]),this._triggerViewEvent(t.ViewEvents.FILTER_MENU_BTN_CLICK)},_onMenuBtnKeyDown:function(e,t){var n=e.which,r=e.target;switch(n){case 32:case 38:case 40:this._consumeEvent(e);if(n===38&&t||n!==38&&!t)return r.click(),!0}return!1},_onFilterMenuBtnKeyDown:function(e){return this._onMenuBtnKeyDown(e,this._filterMenuView.isMenuOpen())},_onUploadMouseDown:function(e){i.isIE()&&!i.isIE9orBelow()&&($(e.target).click(),e.preventDefault())},_onUploadClick:function(){this._logSiteCatalystEvent([u.UPLOAD_ICON,u.CLICKED])},_onNewFolderClick:function(e){var n=this.options;$(e.currentTarget).hasClass("disabled")||(this._logSiteCatalystEvent([u.NEW_FOLDER_ICON,u.CLICKED]),this._triggerViewEvent(t.ViewEvents.NEW_FOLDER,{parentFolderId:n.appApi.folderApi.getCurrentFolderId(n.pluginId),parentView:this,scContext:this._getParentScContext()}))},_onSortMenuBtnClick:function(){this.options.noUrlUpdate?this._logSiteCatalystEvent([u.SORT_ICON,u.CLICKED]):this._logSiteCatalystEvent([u.SEARCH_BAR,u.SORT_ICON,u.CLICKED]),this._triggerViewEvent(t.ViewEvents.SORT_MENU_BTN_CLICK)},_onSortMenuBtnKeyDown:function(e){return this._onMenuBtnKeyDown(e,this._sortMenuView.isMenuOpen())},_onFilesHeaderBtnKeyDown:function(e){var t=this.options,n=$(e.target),r=e.which,o=e.shiftKey,u=this.$btnsRight,a,f=!1,l=this.$("input:file").is(n);switch(r){case 13:case 32:l?i.isIE()&&(t.fileUploadModel.hasAjaxFileUpload()?n.click():r===13&&i.isIE9orBelow()&&(f=!0)):(f=!0,n.click());break;case 9:l&&(a=s.getNextFocusableDescendant(u,o,!0),f=!0);break;case 37:case 38:a=s.getNextFocusableDescendant(u,!0,!0),f=!0;break;case 39:case 40:a=s.getNextFocusableDescendant(u,!1,!0),f=!0}return f&&this._consumeEvent(e),a&&a.focus(),f},_addUiModelEventListeners:function(){var e=this.options,t=e.searchUiModel,n=e.filesUiModel,r=e.searchModel;this.listenTo(t,"change:status",this._onSearchStatusChange).listenTo(n,"change:show_filter_menu",this._onShowFilterMenuChange).listenTo(n,"change:show_sort_menu",this._onShowSortMenuChange),this.listenTo(r,"change:total_hits",this._onSearchResultCountChange)},_onSearchResultCountChange:function(){this.render()},_onSearchStatusChange:function(){this.options.searchUiModel.isSearching()?(this.$newFolder.addClass("disabled").prop("disabled",!0),this.$upload.addClass("disabled"),this.$upload.find("input").prop("disabled",!0)):(this.$newFolder.removeClass("disabled").prop("disabled",!1),this.$upload.removeClass("disabled").prop("disabled",!1),this.$upload.find("input").prop("disabled",!1))},_onShowFilterMenuChange:function(e,t){var n=this._filterMenuView,r,i=this.$filterMenuBtn;t?(r=this.options.filesUiModel,n.open().always(function(){i.removeClass("selected").removeAttr("aria-expanded"),r.set("show_filter_menu",!1,{silent:!0})}),i.addClass("selected").attr("aria-expanded","true")):n.close()},_onShowSortMenuChange:function(e,t){var n=this._sortMenuView,r,i=this.$sortMenuBtn;t?(r=this.options.filesUiModel,n.open().always(function(){i.removeClass("selected").removeAttr("aria-expanded"),r.set("show_sort_menu",!1,{silent:!0})}),i.addClass("selected").attr("aria-expanded","true")):n.close()}}),t.FilesHeaderView}),define("files/dev/templates/folder-template",[],function(){return'
'}),define("files/dev/templates/folder-navigation-template",[],function(){return'
'}),define("files/dev/views/folder-navigation-view",["core/ac-core","files/ac-files","files/templates/folder-navigation-template","i18n!core/nls/ui-strings","i18n!files/nls/ui-strings","core/utils/util","core/utils/breadcrumbs","core/utils/css-util","core/utils/truncate","core/utils/sc-analytics","core/views/view"],function(e,t,n,r,i,s,o,u,a,f){return t.FolderNavigationView=e.View.extend({events:{"click .folder-back-btn":"_onBackButtonClick","click .files-new-folder-btn":"_onNewFolderClick"},initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(n),this._addUiModelEventListeners()},render:function(){var t=this.options;return e.View.prototype.render.call(this),this.$el.children().length===0&&(this.$el.html(this._template({back:r.BACK,newFolder:i.NEW_FOLDER,viewId:t.viewId})),this._initWrappers(),s.isCEF()&&t.appApi.saveAsApi.isRunningInFileSaveAs()&&this.$path.addClass("folder-path-save-as")),this._showFolderPath(),this._showNewFolderButton(),this},_initWrappers:function(){this.$backBtn=this.$(".folder-back-btn"),this.$path=this.$(".folder-path"),this.$newFolder=this.$(".files-new-folder-btn")},_useBreadcrumbs:function(){return this.options.folderUiModel.get("breadcrumbs")},_showNewFolderButton:function(){this.options.showNewFolderInNavigation?this.$newFolder.show():this.$newFolder.hide()},_showFolderPath:function(){var e=this.options,t=s.isCEF(),n=this.$backBtn,r=this.$path,i=e.folderUiModel.get("path"),o=i.length,u=e.appApi.saveAsApi;if(o<=1||e.pluginId==="scan_files"&&o<=2&&i[0].name==="/"){this.$path.children().length>0&&this._clearFolderNavigationPath();if(!e.searchUiModel.showFolders()&&!e.showNavigationAtRoot)return;n.hide(),t&&u.isRunningInFileSaveAs()&&r.addClass("no-back-btn")}else n.show(),t&&u.isRunningInFileSaveAs()&&r.removeClass("no-back-btn");this._useBreadcrumbs()?(e.pluginId==="scan_files"&&i[0].name==="/"&&i.shift(),this._showBreadcrumbs(i)):this._showFolderName(i[o-1].name)},_clearFolderNavigationPath:function(){this.$path.empty()},_showBreadcrumbs:function(n){var i=this.options,a=i.appApi,l=this.$el,c=this.$path,h,p;p=_.bind(function(n){this._logSiteCatalystEvent([f.BREADCRUMB,n===a.folderApi.getRootFolderId(i.pluginId)?f.HOME:"",f.CLICKED]),i.searchUiModel.showFolders()?(i.selectionUiModel.clearSelection(),this._triggerViewEvent(e.ViewEvents.SEARCH_IN_FOLDER,{search_folder_id:n})):this._triggerViewEvent(t.ViewEvents.NAVIGATE_TO_FOLDER,{id:n})},this),h=l.parent().width()-this.$backBtn.position().left-u.getFullWidth(this.$backBtn)-u.getExtraWidth(c),s.isCEF()&&a.saveAsApi.isRunningInFileSaveAs()&&(h-=u.getFullWidth(this.$newFolder)),i.pluginId==="scan_files"?o.display(n,c,h,p,e.Locale.getLocale(),n[0].name):o.display(n,c,h,p,e.Locale.getLocale(),r.HOME)},_showFolderName:function(e){var t=this.$el,n=this.$path,r;n.text(e),r=t.parent().width()-u.getCssNum(n,"left")-u.getCssNum(n,"margin-right"),a.truncateElementText(n,r)},_onBackButtonClick:function(){var n=this.options,r=n.folderModel,i;this._logSiteCatalystEvent([f.BREADCRUMB,f.BACK,f.CLICKED]);if(n.searchUiModel.showFolders()){i=n.folderUiModel.get("path");if(i.length>1||n.pluginId==="scan_files"&&i.length>2&&i[0].name==="/")this.options.selectionUiModel.clearSelection(),this._triggerViewEvent(e.ViewEvents.SEARCH_IN_FOLDER,{search_folder_id:i[i.length-2].id})}else n.collectionsUiModel.set("scroll_id_into_view",r.get("id")),this._triggerViewEvent(t.ViewEvents.NAVIGATE_TO_FOLDER,{id:r.get("parent_id")})},_onNewFolderClick:function(e){var n=this.options.appApi;$(e.currentTarget).hasClass("disabled")||(this._logSiteCatalystEvent([f.NEW_FOLDER_ICON,f.CLICKED]),this._triggerViewEvent(t.ViewEvents.NEW_FOLDER,{parentFolderId:n.saveAsApi.getCurrentFolderId(),parentView:this,scContext:this._getParentScContext()}))},_addUiModelEventListeners:function(){this.options.folderUiModel.on("change:path",this._onFolderPathChange)},_onFolderPathChange:function(){this.render()}}),t.FolderNavigationView}),define("files/dev/templates/no-folder-items-template",[],function(){return'
'}),define("files/dev/views/no-folder-items-view",["core/ac-core","files/ac-files","core/utils/util","core/utils/view-util","files/templates/no-folder-items-template","i18n!files/nls/ui-strings","core/utils/sc-analytics","core/views/view"],function(e,t,n,r,i,s,o){return t.NoFolderItemsView=e.View.extend({events:{"click .files-no-files-upload-file":"_onUploadFileClick","mousedown .files-no-files-upload-file":"_onUploadFileMouseDown"},initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(i),this._addFocusEventListener(),this._addKeyEventListener(),this._addUiModelEventListeners()},render:function(){var t;return e.View.prototype.render.call(this),this.$el.children().length===0&&(this.$el.html(this._template({uploadToAccess:s.UPLOAD_TO_ACCESS,uploadFile:s.UPLOAD_FILE,viewId:this.viewId})),this._initWrappers(),e.Util.isFirefox()&&this.$noFilesUploadFile.addClass("firefox")),this.options.noUpload&&(this.$noFilesPrompt.removeClass("shown"),this.$noFiles.addClass("shown")),t=this._getNoFilesText(),this.$noFilesInFolder1.text(t),this.$noFilesInFolder2.text(t),this.$noFilesInFolder3.attr("id","no-files-in-folder-"+this.cid),this.$el.attr("aria-labelledby","no-files-in-folder-"+this.cid),this},_initWrappers:function(){this.$noFilesPrompt=this.$(".files-no-files-prompt"),this.$noFiles=this.$(".files-no-files").not(".files-no-files-prompt"),this.$noFilesInFolder1=this.$noFilesPrompt.find(".instruction-text.first-line"),this.$noFilesInFolder2=this.$noFiles.find(".instruction-text"),this.$noFilesInFolder3=this.$noFiles.find(".instruction-text.theme-text"),this.$noFilesUploadFile=this.$(".files-no-files-upload-file")},_getNoFilesText:function(){var e=this.options,t=e.collectionsUiModel;return t.get("force_empty")?this._getForceEmptyText():e.pluginId==="scan_files"?s.NO_FILES_IN_FOLDER:e.folderModel.isRoot()?this._getNoFilesRootText():s.NO_FILES_IN_FOLDER},_getForceEmptyText:function(){var e=this.options,t=e.collectionsUiModel,r=t.get("force_empty_msg");return n.isCEF()&&e.appApi.saveAsApi.isRunningInFileSaveAs()?s.NO_FILES_IN_FOLDER:!_.isUndefined(r)&&r!==""?r:s.NO_SEARCH_RESULTS_FOLDER},_getNoFilesRootText:function(){var e=this.options,t=e.pluginId,n=e.appApi.connectorsApi,r;if(n.isConnectorPlugin(t)){r=n.getConnectorPluginLabel(t);if(r&&r!=="")return _.template(s.NO_FILES_IN_CONNECTOR,{connector:r})}return s.NO_FILES_IN_ROOT},_updateUploadButtonFocusStyle:function(e){var t=this.$("input:file");_.defer(function(){!e&&t.is(document.activeElement)?t.addClass("focused"):t.removeClass("focused")})},_onFocusIn:function(){this._updateUploadButtonFocusStyle()},_onFocusOut:function(){this._updateUploadButtonFocusStyle(!0)},_onKeyDown:function(e){var t=$(e.target),i=e.which,s=!1,o;this._updateUploadButtonFocusStyle();if(!r.descendantHasFocus(this.$el))return!1;if(t.is(this.$("input:file")))switch(i){case 13:case 32:n.isIE()&&(this.options.fileUploadModel.hasAjaxFileUpload()?t.click():i===13&&n.isIE9orBelow()&&(s=!0));break;case 9:o=r.getNextFocusableDescendant($("body"),e.shiftKey,!1,":tabbable"),o.length&&(s=!0,o.focus())}return s&&this._consumeEvent(e),s},_onUploadFileMouseDown:function(e){n.isIE()&&!n.isIE9orBelow()&&($(e.target).click(),e.preventDefault())},_onUploadFileClick:function(){this.options.appApi.siteCatalystApi.logScEvent([o.FILE_LIST,o.EMPTY,o.UPLOAD_ICON,o.CLICKED])},_addUiModelEventListeners:function(){var e=this.options;this.listenTo(e.collectionUiModel,"change:show_empty",this._onShowEmptyChange),this.listenTo(e.collectionsUiModel,"change:force_empty",this._onShowEmptyChange)},_onShowEmptyChange:function(e,t){var n=this.options;if(t){if(!n.collectionsUiModel.get("force_empty")&&(!n.folderModel.get("name")||n.searchUiModel.isSearching()))return;this.render(),this.$el.addClass("shown")}else this.$el.removeClass("shown")}}),t.NoFolderItemsView}),define("files/dev/templates/no-virgo-folder-items-template",[],function(){return''}),define("files/dev/views/no-virgo-folder-items-view",["core/ac-core","files/ac-files","core/utils/util","core/utils/view-util","files/templates/no-virgo-folder-items-template","i18n!core/nls/ui-strings","core/utils/sc-analytics","core/views/view"],function(e,t,n,r,i,s,o){return t.NoVirgoFolderItemsView=e.View.extend({events:{"click .learn-about-sending-files-link":"_onLearnLinkClick"},initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(i),this._addUiModelEventListeners()},render:function(){e.View.prototype.render.call(this),this.$el.children().length===0&&(this.$el.html(this._template({NO_PARCELS_SEND_PROMPT:this._getNoFilesText(),NO_PARCELS_SEND_SUBPROMPT:this._getNoFilesSubText(),NO_PARCELS_S_T_BTN:s.NO_PARCELS_S_T_BTN})),this._initWrappers()),this.$titleText.text(this._getNoFilesText()),this.$subtitleText.text(this._getNoFilesSubText());var t=this.options.appApi.connectorsApi.getConnectorPluginName(this.options.pluginId);return t==="root"?(this.$("#emptyStateIcon").removeClass(),this.options.folderModel.isRoot()?(this.$(".empty-state-icon").removeClass(),this.$("#emptyStateIcon").addClass("dc-empty-state-icon")):this.$("#emptyStateIcon").addClass("folder-empty-state-icon"),this.$("#emptyStateIcon").addClass("empty-state-icon")):t==="ccloud"?(this.$("#emptyStateIcon").removeClass(),this.options.folderModel.isRoot()?this.$("#emptyStateIcon").addClass("cc-empty-state-icon"):this.$("#emptyStateIcon").addClass("folder-empty-state-icon"),this.$("#emptyStateIcon").addClass("empty-state-icon")):(this.$("#emptyStateIcon").removeClass(),this.$("#emptyStateIcon").addClass("folder-empty-state-icon"),this.$("#emptyStateIcon").addClass("empty-state-icon")),this},_getNoFilesText:function(){var e=this.options,t=e.collectionsUiModel;if(t.get("force_empty"))return this._getForceEmptyText();var n=this.options.appApi.connectorsApi.getConnectorPluginName(e.pluginId);return n==="root"?e.folderModel.isRoot()?s.VIRGO_EMPTY_DOCUMENT_CLOUD_TITLE:s.VIRGO_EMPTY_FOLDER_TITLE:n==="ccloud"?e.folderModel.isRoot()?s.VIRGO_EMPTY_CREATIVE_CLOUD_TITLE:s.VIRGO_EMPTY_FOLDER_TITLE:s.VIRGO_EMPTY_FOLDER_TITLE},_getNoFilesSubText:function(){var e=this.options.appApi.connectorsApi.getConnectorPluginName(this.options.pluginId);return e==="root"?this.options.folderModel.isRoot()?s.VIRGO_EMPTY_FOLDER_SUBTITLE:s.VIRGO_EMPTY_SUB_FOLDER_SUBTITLE:e==="ccloud"?this.options.folderModel.isRoot()?s.VIRGO_EMPTY_FOLDER_CC_SUBTITLE:s.VIRGO_EMPTY_SUB_FOLDER_SUBTITLE:s.VIRGO_EMPTY_SUB_FOLDER_SUBTITLE},_getForceEmptyText:function(){var e=this.options,t=e.collectionsUiModel,r=t.get("force_empty_msg");return n.isCEF()&&e.appApi.saveAsApi.isRunningInFileSaveAs()?s.NO_FILES_IN_FOLDER:!_.isUndefined(r)&&r!==""?r:s.NO_SEARCH_RESULTS_FOLDER},_initWrappers:function(){this.$noParcelsSendPrompt=this.$("#dc-cc-no-files-prompt"),this.$titleText=this.$(".dc-empty-title"),this.$subtitleText=this.$(".dc-empty-subtitle")},_onLearnLinkClick:function(){this.options.appApi.rnaApi.done(_.bind(function(e){e.openDecoratedUrl(s.LEARN_MORE_ST_GO_URL)},this))},_addUiModelEventListeners:function(){this.listenTo(this.options.collectionUiModel,"change:show_empty",this._onShowEmptyChange)},_onShowEmptyChange:function(e,t){var n=this.options;if(t){if(!n.collectionsUiModel.get("force_empty")&&(!n.folderModel.get("name")||n.searchUiModel.isSearching()))return;this.render(),this.$el.addClass("shown")}else this.$el.removeClass("shown")}}),t.NoVirgoFolderItemsView}),define("files/dev/views/folder-view",["core/ac-core","files/ac-files","files/templates/folder-template","files/views/folder-navigation-view","core/views/view","core/views/collection-view","files/views/no-folder-items-view","files/views/no-virgo-folder-items-view"],function(e,t,n){return t.FolderView=e.View.extend({initialize:function(){e.View.prototype.initialize.call(this),this._addModelEventListeners(),this._addUiModelEventListeners(),this._addAppApiCallbacks()},render:function(){var t=this.$el;e.View.prototype.render.call(this),t.children().length===0&&(t.html(_.template(n)),this._initWrappers()),this._renderChildViews();var r=this.options;if(this.options.appApi.saveAsApi.isRunningInFileSaveAs()||this.options.appApi.selectionApi.isRunningInFileSelection())this._updateFolderNavigationView();else{var i=this.options.appApi.connectorsApi.getConnectorPluginName(r.pluginId);i==="root"&&this.$folderItems.attr("id","dcFolderItems"),i==="ccloud"&&this.$folderItems.attr("id","ccFolderItems"),r.pluginId==="scan_files"&&this.$folderItems.attr("id","scanFolderItems")}return this},_initWrappers:function(){this.$folderNavigation=this.$(".folder-navigation"),this.$folderItems=this.$(".folder-items"),this.$noFolderItems=this.$(".old-view-folder-items"),this.$noVirgoFolderItems=this.$(".files-virgo-no-folder-items")},_renderChildViews:function(){var t=this._collectionUiModel;t||(t=this._collectionUiModel=e.uiModelFactory.create("CollectionUiModel")),(this.options.appApi.saveAsApi.isRunningInFileSaveAs()||this.options.appApi.selectionApi.isRunningInFileSelection())&&this._renderFolderNavigationView(t),this.options.appApi.saveAsApi.isRunningInFileSaveAs()||this.options.appApi.selectionApi.isRunningInFileSelection()?this._renderNoFolderItemsView(t):this._renderVirgoNoFolderItemsView(t),this._renderFolderItemsView(t)},_renderFolderNavigationView:function(e){this._renderChildView("_folderNavigationView",t.FolderNavigationView,this.$folderNavigation,{collectionUiModel:e})},_renderFolderItemsView:function(t){this._renderChildView("_folderItemsView",e.CollectionView,this.$folderItems,{collection:this.options.folderModel.get("items"),collectionUiModel:t})},_renderNoFolderItemsView:function(n){var r=this.options.noUpload,i=e.Util;if(this.options.appApi.acrobatApi.isInAcrobat()||(i.isIpad()||i.isIphone())&&(i.isIosVersion(5)||i.isIosVersion(4)))r=!0;this._renderChildView("_noFolderItemsView",t.NoFolderItemsView,this.$noFolderItems,{collectionUiModel:n,noUpload:r})},_renderVirgoNoFolderItemsView:function(n){var r=this.options.noUpload,i=e.Util;if(this.options.appApi.acrobatApi.isInAcrobat()||(i.isIpad()||i.isIphone())&&(i.isIosVersion(5)||i.isIosVersion(4)))r=!0;this._renderChildView("_noVirgoFolderItemsView",t.NoVirgoFolderItemsView,this.$noVirgoFolderItems,{collectionUiModel:n,noUpload:r})},_updateFolderNavigationView:function(){var e=this.$folderNavigation,t=this.$folderItems,n=this.options;!this.options.showNavigationAtRoot&&this.options.folderModel.isRoot()||n.pluginId==="scan_files"&&!this.options.showNavigationAtRoot&&this.options.folderModel.get("parent_id")===n.appApi.folderApi.getRootFolderId()?(e.removeClass("shown"),t.removeClass("with-folder-navigation")):(e.addClass("shown"),t.addClass("with-folder-navigation"))},_addModelEventListeners:function(){this.listenTo(this.options.folderModel,"change:object_type",this._onObjectTypeChange).listenTo(this.options.folderModel,"change:name",this._onNameChange)},_onObjectTypeChange:function(){var e=this.options.folderModel;this.options.pluginId!=="scan_files"&&(e.previous("object_type")||e.get("object_type")!=="root")&&this.render()},_onNameChange:function(){var e=this.options.folderModel;this.options.pluginId==="scan_files"&&this.render()},_addUiModelEventListeners:function(){this.listenTo(this.options.searchUiModel,"change:status",this._onSearchStatusChange)},_onSearchStatusChange:function(e){var t=e.isSearchClosed();this._collectionUiModel.set("is_active",t),t&&this.render()},_addAppApiCallbacks:function(){var e=this.options,t=e.folderModel,n=e.appApi.connectorsApi,r=n.getConnectorPluginName(e.pluginId);n.isDesktopConnector(r)||e.appApi.sessionApi.addSignedInChangeCallback(function(e,n){n||t.unset("id").get("items").reset()})}}),t.FolderView}),define("files/dev/templates/export-options-template",[],function(){return'
<%= exportFormatHeader %>
<%= exportSettings %>
<%= viewResult %>
'}),define("files/dev/views/export-options-view",["core/ac-core","files/ac-files","files/templates/export-options-template","i18n!files/nls/ui-strings","core/views/view"],function(e,t,n,r){return t.ExportOptionsView=e.View.extend({events:{"click .export-settings-btn":"_onSettingsButtonClicked","click .export-view-result":"_onViewResultCheckboxClicked","keydown .export-settings-btn":"_onKeyDownSettingsButton","keydown .export-view-result":"_onKeyDownCheckbox"},initialize:function(){e.View.prototype.initialize.call(this),this.saveAsApi=this.options.appApi.saveAsApi},render:function(){return e.View.prototype.render.call(this),this.$el.children().length===0&&(this._template=_.template(n)({exportFormatHeader:r.EXPORT_FILE_FORMAT,exportFormat:this.saveAsApi.getChosenFilterDescription(),exportSettings:r.EXPORT_SETTINGS,viewResult:r.EXPORT_VIEW_RESULT}),this.$el.html(this._template),this._initWrappers(),this._setInitialStateOfElements()),this},_initWrappers:function(){this.$settingsBtn=this.$(".export-settings-btn"),this.$viewResult=this.$(".export-view-result"),this.$viewResultCheckbox=this.$viewResult.find(".checkbox")},_setInitialStateOfElements:function(){this.saveAsApi.isSettingsButtonVisible().done(_.bind(function(e){e===!0?this.$settingsBtn.show():this.$settingsBtn.hide()},this)),this.saveAsApi.isViewResultVisible().done(_.bind(function(e){e===!0?this.saveAsApi.isViewResultChecked().done(_.bind(function(e){this.$viewResult.show(),this._setViewResultCheckboxState(e)},this)):this.$viewResult.hide()},this))},_onSettingsButtonClicked:function(){this.saveAsApi.settingsButtonExecute()},_onKeyDownSettingsButton:function(e){var t=e.which?e.which:e.keyCode;t==32&&this.saveAsApi.settingsButtonExecute()},_onKeyDownCheckbox:function(e){var t=e.which?e.which:e.keyCode;t==32&&this._onViewResultCheckboxClicked()},_onViewResultCheckboxClicked:function(){this.saveAsApi.isViewResultChecked().done(_.bind(function(e){var t=!e;this._setViewResultCheckboxState(t),this.saveAsApi.setViewResultChecked(t)},this))},_setViewResultCheckboxState:function(e){e?this.$viewResultCheckbox.addClass("selected"):this.$viewResultCheckbox.removeClass("selected")}}),t.ExportOptionsView}),define("files/dev/templates/full-preview-template",[],function(){return'
<%- name %>
<%= previewNotAvailable %> <%= previewNotAvailableDesc %>
'}),define("files/dev/views/full-preview-home-btn-view",["core/ac-core","files/ac-files","core/templates/toolbar-item-template","core/views/plugin-selector-view"],function(e,t,n){return t.FullPreviewHomeBtnView=e.PluginSelectorView.extend({render:function(){this.options.template=_.template(n),e.PluginSelectorView.prototype.render.call(this)},getSelectorIconClass:function(){return"full-preview-home-btn"}}),t.FullPreviewHomeBtnView}),define("files/dev/templates/full-preview-action-menu-template",[],function(){return' '}),define("files/dev/views/full-preview-action-menu-view",["core/ac-core","files/ac-files","files/templates/full-preview-action-menu-template","i18n!core/nls/ui-strings","core/utils/css-util","core/utils/sc-analytics","core/views/menu-view"],function(e,t,n,r,i,s){return t.FullPreviewActionMenuView=e.MenuView.extend({events:function(){return _.extend({},e.MenuView.prototype.events,{"click .full-preview-rename-menu-item":"_onRenameClick","click .full-preview-share-menu-item":"_onShareClick","click .full-preview-delete-menu-item":"_onDeleteClick"})},render:function(){var t=this.$el;e.MenuView.prototype.render.call(this),t.children().length===0&&(t.html(_.template(n)({rename:r.RENAME_ELLIPSIS,share:r.SHARE_ELLIPSIS,deleteText:r.DELETE})),(!e.Features.isFeatureEnabled("share_ui")||this.options.noShare)&&$(".full-preview-share-menu-item").hide())},open:function(){var t=this.options,n=e.MenuView.prototype.open.call(this),r=this.$el,o;return this._logSiteCatalystEvent(s.SHOWN),o=t.$actionMenuBtn.position(),r.css("left",o.left-i.getFullWidth(r)+42+"px"),n},_getSiteCatalystContext:function(){var e=this.options.fullPreviewUiModel;return e.isNGDocView()&&e.isNGDocJobComplete()?[s.NGDOC,s.TOOLBAR,s.GEAR_MENU]:[s.TOOLBAR,s.GEAR_MENU]},_onRenameClick:function(){var t=this.options,n;this.close(_.bind(function(){this._logSiteCatalystEvent([s.RENAME,s.CLICKED]);var r=t.fullPreviewUiModel.get("item_model");n=r.get("name"),this._triggerViewEvent(e.ViewEvents.RENAME,{id:r.get("id"),object_type:r.get("object_type"),name:n,existingName:n,model:r,parentView:this,scContext:this._getFullScContext()})},this))},_onShareClick:function(){var t=this.options;this.close(_.bind(function(){this._logSiteCatalystEvent([s.SHARE,s.CLICKED]);var n=t.fullPreviewUiModel.get("item_model");this._triggerViewEvent(e.ViewEvents.SHOW_PUBLIC_SHARE_DLG,{models:[n],parentView:this,scContext:this._getFullScContext()})},this))},_onDeleteClick:function(){var e=this.options;this.close(_.bind(function(){this._logSiteCatalystEvent([s.DELETE,s.CLICKED]),this._triggerViewEvent(t.ViewEvents.FULL_PREVIEW_DELETE,{id:e.fullPreviewUiModel.get("item_model").id,object_type:"file",parentView:this,scContext:this._getFullScContext()})},this))}}),t.FullPreviewActionMenuView}),define("files/dev/templates/full-preview-hud-template",[],function(){return' '}),define("files/dev/templates/full-preview-file-info-template",[],function(){return'
<%= fileName %>
<%= typeLabel %> <%= fileType %>
<%= addedLabel %> <%= dateAdded %>
<%= modifiedLabel %> <%= dateModified %>
<%= sizeLabel %> <%= fileSize %>
'}),define("files/dev/views/full-preview-file-info-view",["core/ac-core","files/ac-files","files/templates/full-preview-file-info-template","i18n!core/nls/ui-strings","i18n!files/nls/ui-strings","core/utils/css-util","core/utils/num-util","core/utils/date-util","core/utils/file-types","core/utils/truncate","core/views/menu-view"],function(e,t,n,r,i,s,o,u,a,f){return t.FullPreviewFileInfoView=e.MenuView.extend({template:_.template(n),render:function(){var t=this.$el,n;e.MenuView.prototype.render.call(this),t.html(this.template({fileName:this._getFileName(),typeLabel:i.TYPE,fileType:this._formatFileType(),addedLabel:r.ADDED,dateAdded:this._formatDateAdded(),modifiedLabel:r.MODIFIED,dateModified:this._formatDateModified(),sizeLabel:r.SIZE,fileSize:this._formatFileSize()})),this._initWrappers(),f.truncateElementText(this.$fileName),n=this.options.$toggleInfoBtn.offset(),t.css("left",Math.max(n.left-s.getFullWidth(t)+42,0)+"px")},_onBodyClick:function(t){e.MenuView.prototype._onBodyClick.call(this,t),$(t.target).closest(this.options.$toggleInfoBtn).length>0&&this._consumeEvent(t)},_initWrappers:function(){this.$fileName=this.$(".files-full-preview-file-info-name")},_getItemModel:function(){return this.options.fullPreviewUiModel.get("item_model")},_formatDate:function(e){var t=this._getItemModel();return t?u.formatDate(t.get(e)):""},_getFileName:function(){return this.options.fullPreviewUiModel.getFileName()},_formatFileType:function(){return a.formatFileType(this._getItemModel())},_formatDateAdded:function(){return this._formatDate("created")},_formatDateModified:function(){return this._formatDate("modified")},_formatFileSize:function(){var e=this._getItemModel();return e?o.formatSize(e.get("size")):""}}),t.FullPreviewFileInfoView}),define("files/dev/views/full-preview-hud-view",["core/ac-core","files/ac-files","files/templates/full-preview-hud-template","i18n!core/nls/ui-strings","i18n!files/nls/ui-strings","core/utils/util","core/utils/view-util","core/utils/num-util","core/utils/sc-analytics","core/views/view","files/views/full-preview-file-info-view"],function(e,t,n,r,i,s,o,u,a){var f=.8,l=1.25;return t.FullPreviewHudView=e.View.extend({events:{mouseenter:"_onMouseEnter",mousemove:"_onMouseMove",mouseleave:"_onMouseLeave","click .full-preview-hud-prev":"_onPrevPageClick","click .full-preview-hud-next":"_onNextPageClick","keydown .full-preview-hud-page-num":"_onPageNumKeyDown","keyup .full-preview-hud-page-num":"_onPageNumKeyUp","click .full-preview-hud-zoom-out":"_onZoomOutClick","click .full-preview-hud-zoom-in":"_onZoomInClick","click .full-preview-hud-scroll-pages":"_onScrollPagesClick","click .full-preview-hud-fit-page-width":"_onFitPageWidthClick","click .full-preview-hud-fit-full-page":"_onFitFullPageClick","click .full-preview-hud-toggle-rhp":"_onToggleRhpClick","click .full-preview-hud-toggle-info":"_onToggleInfoClick","click .full-preview-hud-toggle-ngdoc":"_onToggleNgdocClick","click .full-preview-hud-close":"_onCloseClick","click .full-preview-hud-dock":"_onDockClick","touchstart .full-preview-hud-prev":"_onPrevPageClick","touchstart .full-preview-hud-next":"_onNextPageClick","touchstart .full-preview-hud-page-num":"_onPageNumTap","touchstart .full-preview-hud-zoom-out":"_onZoomOutClick","touchstart .full-preview-hud-zoom-in":"_onZoomInClick","touchstart .full-preview-hud-scroll-pages":"_onScrollPagesClick","touchstart .full-preview-hud-fit-page-width":"_onFitPageWidthClick","touchstart .full-preview-hud-fit-full-page":"_onFitFullPageClick","touchstart .full-preview-hud-toggle-rhp":"_onToggleRhpClick","touchstart .full-preview-hud-toggle-info":"_onToggleInfoClick","touchstart .full-preview-hud-toggle-ngdoc":"_onToggleNgdocClick","touchstart .full-preview-hud-close":"_onCloseClick","touchstart .full-preview-hud-dock":"_onDockClick"},initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(n),this._addUiModelEventListeners(),this._addFocusEventListener()},render:function(){e.View.prototype.render.call(this),this.$el.children().length===0&&(this.$el.html(this._template({prevPageTitle:i.PREV_PAGE_TITLE,nextPageTitle:i.NEXT_PAGE_TITLE,pageNumTitle:i.PAGE_NUM_TITLE,pageNumSeparator:i.PAGE_NUM_SEPARATOR,pageCountTitle:i.PAGE_COUNT_TITLE,zoomOutTitle:i.ZOOM_OUT_TITLE,zoomInTitle:i.ZOOM_IN_TITLE,scrollPagesTitle:i.SCROLL_PAGES_TITLE,fitPageWidthTitle:i.FIT_PAGE_WIDTH_TITLE,fitFullPageTitle:i.FIT_FULL_PAGE_TITLE,unDockTitle:i.UNDOCK,dockTitle:i.DOCK_TO_BOTTOM,closeTitle:r.CLOSE})),this._initWrappers(),s.isTouchDevice()&&this.$pageNum.attr("readonly","readonly").addClass("readonly")),this.$pageNum.val(this._getPageNumStr()),this.$pageCount.html(this._getPageCountStr());var t=this._getToggleRhpTitle(),n=this._getToggleInfoTitle(),o=this._getToggleNgdocTitle();this.$toggleRhp.attr("title",t).find(".hidden-accessible").text(t),this.$toggleInfo.attr("title",n).find(".hidden-accessible").text(n),this.$toggleNgdoc.attr("title",o).find(".hidden-accessible").text(o),this._updateControls(),this.options.fullPreviewUiModel.get("is_hud_dismissed")||this._show(!0),this._renderChildViews()},_initWrappers:function(){this.$prevPage=this.$(".full-preview-hud-prev"),this.$nextPage=this.$(".full-preview-hud-next"),this.$pageNum=this.$(".full-preview-hud-page-num"),this.$pageCount=this.$(".full-preview-hud-page-count"),this.$viewBtns=this.$(".full-preview-hud-scroll-pages,.full-preview-hud-fit-page-width,.full-preview-hud-fit-full-page"),this.$scrollPages=this.$(".full-preview-hud-scroll-pages"),this.$fitPageWidth=this.$(".full-preview-hud-fit-page-width"),this.$fitFullPage=this.$(".full-preview-hud-fit-full-page"),this.$toggleRhp=this.$(".full-preview-hud-toggle-rhp"),this.$toggleInfo=this.$(".full-preview-hud-toggle-info"),this.$toggleNgdoc=this.$(".full-preview-hud-toggle-ngdoc"),this.$close=this.$(".full-preview-hud-close"),this.$dock=this.$(".full-preview-hud-dock"),this.$fileInfo=this.$(".files-full-preview-file-info"),this.$hudControls=this.$(".full-preview-hud-controls")},_getPageNum:function(){return this.options.fullPreviewUiModel.get("current_page")},_getPageCount:function(){return this.options.fullPreviewUiModel.get("page_count")},_getPageNumStr:function(){return this._getPageCount()?(this._getPageNum()+1).toString():""},_getPageCountStr:function(){var e=this._getPageCount();return e?e.toString():" "},_getToggleRhpTitle:function(){return this.options.fullPreviewUiModel.get("show_rhp")?i.HIDE_RHP:i.SHOW_RHP},_getToggleInfoTitle:function(){return this.options.fullPreviewUiModel.get("show_info")?i.HIDE_FILE_INFO:i.SHOW_FILE_INFO},_getToggleNgdocTitle:function(){return this.options.fullPreviewUiModel.isNGDocView()?i.SHOW_IMAGE_PREVIEW:i.SHOW_NGDOC_PREVIEW},_updateControls:function(){var e,t,n;e=this.options.fullPreviewUiModel,t=this._getPageNum(),n=this._getPageCount(),t===0?(this.$prevPage.is(document.activeElement)&&this.$nextPage.focus(),o.enableInput(this.$prevPage,!1)):o.enableInput(this.$prevPage,!0),t===n-1?(this.$nextPage.is(document.activeElement)&&this.$prevPage.focus(),o.enableInput(this.$nextPage,!1)):o.enableInput(this.$nextPage,!0),this._updateCurrentPageNumber(),this.$viewBtns.removeClass("disabled").attr("aria-pressed","false"),e.isScrollPagesView()?this.selectedViewButton=this.$scrollPages:e.isFitFullPageView()?this.selectedViewButton=this.$fitFullPage:this.selectedViewButton=this.$fitPageWidth,this.selectedViewButton.addClass("disabled").attr("aria-pressed","true"),e.get("show_rhp")?this.$toggleRhp.addClass("show-rhp"):this.$toggleRhp.removeClass("show-rhp"),e.get("enable_ngdoc")&&e.isNGDocJobComplete()?(this.$toggleNgdoc.show(),e.isNGDocView()?this.$toggleNgdoc.removeClass("show-image"):this.$toggleNgdoc.addClass("show-image")):this.$toggleNgdoc.hide(),e.get("is_hud_dismissed")||s.isTouchDevice()?(this.$close.css("display","none"),this.$dock.css("display","")):(this.$close.css("display","inline-block"),this.$dock.css("display","none"))},_updateCurrentPageNumber:function(){this.$pageNum.val(this._getPageNum()+1)},_updateHudPosition:function(){var e=this.options.fullPreviewUiModel;e.get("is_hud_dismissed")||(o.isHorizontalScrollBarPresent(e.get("preview_elem"))?this.$el.css("bottom",o.getScrollBarWidth()+"px"):this.$el.css("bottom","0px"))},_show:function(e){if(!this._getPageCount())return;if(e===this._isShown){e&&s.isTouchDevice()&&this._updateCurrentPageNumber();return}this.$el.stop(!0,!1),this.$el.animate({opacity:e?1:0},_.bind(function(){e||this._updateControls()},this)),this._isShown=e,e?(this.options.fullPreviewUiModel.get("is_hud_dismissed")?(this.$el.addClass("full-preview-hud-floating"),this.$hudControls.addClass("full-preview-hud-controls-floating"),this.$toggleNgdoc.is(":visible")?this.$hudControls.addClass("ngdoc"):this.$hudControls.removeClass("ngdoc")):(this.$el.removeClass("full-preview-hud-floating"),this.$hudControls.removeClass("full-preview-hud-controls-floating ngdoc")),this._updateControls(),this._updateCurrentPageNumber()):this.$pageNum&&this.$pageNum.blur()},_renderChildViews:function(){this._renderFileInfoView()},_renderFileInfoView:function(){this._renderChildView("_fullPreviewFileInfoView",t.FullPreviewFileInfoView,this.$fileInfo,{$toggleInfoBtn:this.$toggleInfo,animate:!1})},_onMouseEnter:function(e){$(e.currentTarget).is(this.$el)&&(this._isMouseEntered=!0,this._show(!0))},_onMouseMove:function(e){var t,n=e.pageX,r=e.pageY,i,s,u,a,f,l,c,h=this.$el;t=this.options.fullPreviewUiModel.get("preview_elem");if(!o.isVerticalScrollBarPresent(t)){h.css("width","100%");return}i=this.$el.offset(),a=i.left+this.$el.width(),f=i.top+this.$el.height(),l=o.getScrollBarWidth(),s=a-l,u=i.top,c=n>=s&&n<=a&&r>=u&&r<=f,c&&!this._wasOverScrollBar?h.width(h.width()-l):h.css("width","100%"),this._wasOverScrollBar=c,this._show(!c)},_onMouseLeave:function(e){var t=this.options.fullPreviewUiModel;$(e.currentTarget).is(this.$el)&&(this._isMouseEntered=!1,t.get("is_hud_dismissed")&&$(document.activeElement).closest(this.$el).length===0&&this._show(!1))},_timeoutId:null,_onFocusIn:function(e){clearTimeout(this._timeoutId);var t=this.options.fullPreviewUiModel;t.get("is_hud_dismissed")&&$(e.target).closest(this.$el)!==0&&this._show(!0)},_onFocusOut:function(){var e=this.options.fullPreviewUiModel,t=this.$el,n=this;e.get("is_hud_dismissed")&&(this._timeoutId=setTimeout(function(){e.get("is_hud_dismissed")&&!n._isMouseEntered&&$(document.activeElement).closest(t).length===0&&n._show(!1)},10))},_onPrevPageClick:function(e){this._onPageNavClick(e,!1)},_onNextPageClick:function(e){this._onPageNavClick(e,!0)},_onPageNavClick:function(e,t){var n;e&&e.preventDefault();if(!e||!$(e.currentTarget).hasClass("disabled"))this._logSiteCatalystEvent(t?a.NEXT_PAGE:a.PREV_PAGE),n=this._getPageNum(),this._goToPage(t?n+1:n-1,!0)},_goToPage:function(e,t){var n=this.options.fullPreviewUiModel,r=n.get("current_page");n.set({current_page:Math.min(Math.max(0,e),this._getPageCount()-1),align_current_page:t}),r===n.get("current_page")&&this._updateCurrentPageNumber()},_onPageNumKeyDown:function(e){var t=this.$pageNum,n=_.bind(function(){this._updateCurrentPageNumber(),t.blur().focus(),t.select()},this),r=_.bind(function(){var e=parseInt(this.$pageNum.val(),10);isNaN(e)?n():(this._logSiteCatalystEvent(a.PAGE_NUM_ENTERED),this._goToPage(e-1,!0),s.isTouchDevice()&&t.blur())},this),i=e.which;i===27?n():i===13||i===9?r():(i===37||i===39)&&e.stopPropagation()},_onPageNumKeyUp:function(){var e=this.$pageNum,t=e.val(),n=u.removeNonNumerics(t);n!==t&&e.val(n)},_onPageNumTap:function(){var e=this.$pageNum;e.attr("readonly")!=="readonly"&&e.focus().select()},_onZoomOutClick:function(e){var t=this.options.fullPreviewUiModel,n=t.get("zoom_factor");if($(e.currentTarget).hasClass("disabled"))return;t.set({align_current_page:!0,zoom_factor:n*f}),this._updateHudPosition(),this._logSiteCatalystEvent(a.ZOOM_OUT)},_onZoomInClick:function(e){var t=this.options.fullPreviewUiModel,n=t.get("zoom_factor");if($(e.currentTarget).hasClass("disabled"))return;t.set({align_current_page:!0,zoom_factor:n*l}),this._updateHudPosition(),this._logSiteCatalystEvent(a.ZOOM_IN)},_onScrollPagesClick:function(e){this._onViewButtonClick(e,"scroll_pages")&&this._logSiteCatalystEvent(a.SCROLL)},_onFitPageWidthClick:function(e){this._onViewButtonClick(e,"fit_page_width")&&this._logSiteCatalystEvent(a.FIT_PAGE_WIDTH)},_onFitFullPageClick:function(e){this._onViewButtonClick(e,"fit_full_page")&&this._logSiteCatalystEvent(a.FIT_FULL_PAGE)},_onViewButtonClick:function(e,t){return $(e.currentTarget).hasClass("disabled")?!1:(this.options.fullPreviewUiModel.set({view_format:t,align_current_page:!0,zoom_factor:1}),this._updateHudPosition(),!0)},_onToggleRhpClick:function(e){var n=this.options,r=n.fullPreviewUiModel,i=r.get("show_rhp");e.preventDefault(),this._logSiteCatalystEvent(i?a.HIDE_RHP:a.SHOW_RHP),r.set("show_rhp",!i),t.opFactory.create("SavingFilesPrefsOp",n).run()},_onToggleInfoClick:function(e){var t=this.options,n=t.fullPreviewUiModel,r=n.get("show_info");e.preventDefault(),this._logSiteCatalystEvent(r?a.HIDE_FILE_INFO:a.SHOW_FILE_INFO),n.set("show_info",!r)},_onToggleInfoKeyDown:function(e){var t=this.options,n=t.fullPreviewUiModel,r=n.get("show_info"),i=e.which;switch(i){case 32:case 38:case 40:case 27:return(r&&(i===38||i===27)||!r&&i===40||i===32)&&this._onToggleInfoClick(e),this._consumeEvent(e),!0}return!1},_onToggleNgdocClick:function(e){var t=this.options,n=t.fullPreviewUiModel,r;e.preventDefault();if(!n.get("enable_ngdoc"))return;r=n.isNGDocView(),this._logSiteCatalystEvent(r?a.SHOW_IMAGE_PREVIEW:a.SHOW_NGDOC_PREVIEW),n.set({view_type:r?"bitmap":"ngdoc"})},_onDockClick:function(){var e=this,t=this.options.fullPreviewUiModel,n=this.$dock.is(document.activeElement);this._show(!1),t.set("is_hud_dismissed",!1),this._show(!0),n&&_.delay(function(){e.$close.focus()},t.get("restore_focus_delay")/5)},_onCloseClick:function(){var e=this,t=this.options.fullPreviewUiModel,n=this.$close.is(document.activeElement);this._logSiteCatalystEvent(a.CLOSE),t.set("is_hud_dismissed",!0),this._show(!1),n&&_.delay(function(){e.$dock.focus()},t.get("restore_focus_delay"))},_onKeyDown:function(e){var t=e.which,n=!1,r=this.options.fullPreviewUiModel,i=this.$el,s=$(e.target),u,a=o.descendantHasFocus(i);if(s.is("[aria-haspopup=true],[role=option],[role^='menuitem'],[role=toolbar] :focusable")&&!a)return!1;if(s.is(this.$toggleInfo)&&this._onToggleInfoKeyDown(e))return!0;switch(t){case 27:s.closest(".generic-dialog, [role=dialog], [role=menu]").length===0&&this.options.appApi.previewApi.closeFullPreview(),n=!0;break;case 35:this._goToPage(r.get("page_count")-1,!0),n=!0;break;case 36:this._goToPage(0,!0),n=!0;break;case 33:case 38:this._onPrevPageClick(),n=!0;break;case 34:case 40:this._onNextPageClick(),n=!0;break;case 37:a?u=o.getNextFocusableDescendant(i,!0,!1):(this._onPrevPageClick(),n=!0);break;case 39:a?u=o.getNextFocusableDescendant(i,!1,!1):(this._onNextPageClick(),n=!0);break;case 65:if(e.ctrlKey||e.metaKey)r.isNGDocView()||(n=!0)}return u&&u.length&&(this._consumeEvent(e),n=!0,u.focus()),n},_getSiteCatalystContext:function(){var e=this.options.fullPreviewUiModel;return e.isNGDocView()&&e.isNGDocJobComplete()?[a.NGDOC,a.BOTTOM_NAV_BAR]:a.BOTTOM_NAV_BAR},_addUiModelEventListeners:function(){var e=this.options.fullPreviewUiModel;this.listenTo(e,"change:item_model",this._onItemModelChange).listenTo(e,"change:page_count",this._onPageCountChange).listenTo(e,"change:current_page",this._onCurrentPageChange).listenTo(e,"change:show_info",this._onShowInfoChange)},_onItemModelChange:function(e,t){t||this.options.appApi.keyApi.popKeyHandler(this)},_onPageCountChange:function(e,t){t&&(this.render(),this.options.appApi.keyApi.pushKeyHandler(this))},_onCurrentPageChange:function(e,t){this._goToPage(t,e.get("align_current_page"))},_onShowInfoChange:function(e,t){var n=this._fullPreviewFileInfoView,r;t?(r=this.options.fullPreviewUiModel,n.open().always(function(){r.set("show_info",!1)})):n.close(),this.render()}}),t.FullPreviewHudView}),define("files/dev/templates/full-preview-toolbar-item-template",[],function(){return''}),define("files/dev/views/full-preview-plugins-selector-view",["core/ac-core","files/ac-files","files/templates/full-preview-toolbar-item-template","core/utils/css-util","core/views/plugins-selector-view"],function(e,t,n,r){return t.FullPreviewPluginsSelectorView=e.PluginsSelectorView.extend({initialize:function(){e.PluginsSelectorView.prototype.initialize.call(this)},render:function(){e.PluginsSelectorView.prototype.render.call(this),this.options.pluginsUiModel.getShownPluginCount()<=1?this.$el.hide():this._positionPointer()},_getSelectorTemplate:function(){return n},_getSelectorViewEvent:function(){return t.ViewEvents.FULL_PREVIEW_PLUGIN_CLICK},_initWrappers:function(){e.PluginsSelectorView.prototype._initWrappers.call(this),this.$pointer=this.$(".toolbar-selection-pointer")},_positionPointer:function(){var e=this._getSelectedSelectorElement(),t=this.options.fullPreviewUiModel.get("show_rhp"),n=this.$pointer,i;this.$el.show(),e&&t?(n.width(e.find(".plugin-selector-icon").width()),i=r.getFullWidth(e),n.show().css("left",e.position().left+1+(i-n.width())/2+"px")):(this._unhighlightSelection(),n.hide())},_onPluginSelectorClick:function(n){var r=this.options,i=r.fullPreviewUiModel;i.get("show_rhp")||(i.set("show_rhp",!0),t.opFactory.create("SavingFilesPrefsOp",r).run()),e.PluginsSelectorView.prototype._onPluginSelectorClick.call(this,n)}}),t.FullPreviewPluginsSelectorView}),define("files/dev/templates/full-preview-plugins-content-template",[],function(){return'
'}),define("files/dev/views/full-preview-plugins-content-view",["core/ac-core","files/ac-files","files/templates/full-preview-plugins-content-template","core/views/plugins-content-view"],function(e,t,n){return t.FullPreviewPluginsContentView=e.PluginsContentView.extend({_getContentTemplate:function(){return n}}),t.FullPreviewPluginsContentView}),define("files/dev/templates/full-preview-overlays-content-template",[],function(){return'
'}),define("files/dev/views/full-preview-overlays-content-view",["core/ac-core","files/ac-files","files/templates/full-preview-overlays-content-template","core/views/plugins-content-view"],function(e,t,n){return t.FullPreviewOverlaysContentView=e.PluginsContentView.extend({render:function(){var t=this.$el,r,i=this.options.fullPreviewOverlaysUiModel,s=this.options.bScrollPageView,o,u,a,f,l,c,h;e.View.prototype.render.call(this),r=_.template(n),t.children(".full-preview-overlay-content").length===0&&(o=i.get("plugins"),o&&o.each(function(e){var n=_.clone(e.get("preview_elems"));t.append(r()),s?(n.push(t.children().last()),e.set("preview_elems",n)):e.set("content_elem",t.children().last())}),this._initWrappers()),s?(l=this.$el.find(".full-preview-image"),c=this.$el.find(".full-preview-svg")):(l=this.$el.find(".full-preview-image").not(".scroll-pages"),c=this.$el.find(".full-preview-svg").not(".scroll-pages")),l.length!==0&&l.is(":visible")?(this.$contents.css({"margin-top":l.css("margin-top"),"margin-left":l.css("margin-left"),"margin-bottom":l.css("margin-bottom"),"margin-right":l.css("margin-right"),left:l.offset().left+"px"}),this.$contents.width(l.width()).height(l.height())):c.length!==0&&c.is(":visible")&&(this.$contents.css({"margin-top":c.css("margin-top"),"margin-left":c.css("margin-left"),"margin-bottom":c.css("margin-bottom"),"margin-right":c.css("margin-right"),left:c.offset().left+"px"}),this.$contents.width(c.width()).height(c.height())),this.$contents.removeClass("selected"),a=i.getSelectedId(),u=i.get("plugins").get(a),h=l.hasClass("hidden")&&c.hasClass("hidden"),u&&(s?_.each(u.get("preview_elems"),function(e){h||e.addClass("selected")}):h||u.get("content_elem").addClass("selected"),f=u.get("plugin_api"),f&&s===!1&&f.render())},remove:function(){var t=this.options.fullPreviewOverlaysUiModel,n;this.$el.find(".full-preview-overlay-content").remove(),n=t.get("plugins"),n&&n.each(function(e){e.get("preview_elems").length!==0&&e.set("preview_elems",[])}),e.View.prototype.remove.call(this)},_getContentTemplate:function(){return n},_initWrappers:function(){this.$contents=this.$el.children(".plugin-content")}}),t.FullPreviewOverlaysContentView}),define("files/dev/views/full-preview-view",["core/ac-core","files/ac-files","files/templates/full-preview-template","i18n!core/nls/ui-strings","core/utils/truncate","core/utils/image-loader","core/utils/css-util","core/utils/comment-util","core/utils/sc-analytics","core/utils/svg-loader","core/views/view","files/views/view-events","files/views/full-preview-home-btn-view","files/views/full-preview-action-menu-view","files/views/full-preview-hud-view","files/views/full-preview-plugins-selector-view","files/views/full-preview-plugins-content-view","files/views/full-preview-overlays-content-view"],function(e,t,n,r,i,s,o,u,a,f){var l="application/pdf",c=1200;return t.FullPreviewView=e.View.extend({viewEvents:{"click .full-preview-home-btn":"_onHomeBtnClick","click .full-preview-action-menu-btn":"_onActionMenuBtnClick","click .full-preview-download-btn":"_onDownloadClick","click .full-preview-send-btn":"_onSendClick","click .preview-download":"_onPreviewDownloadClick","keydown .full-preview-action-menu-btn":"_onActionMenuBtnKeyDown"},initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(n),this._addUiModelEventListeners(),this._addAppApiCallbacks()},template:function(){return _.template(n)},render:function(){var t=this.$el,n=this.options,i=n.fullPreviewUiModel;e.View.prototype.render.call(this);if(!i.get("item_model"))return;t.children().length===0&&(t.html(this.template()({actions:r.ACTIONS,back:r.BACK,download:r.DOWNLOAD,send:r.SEND,previewNotAvailable:r.PREVIEW_NOT_AVAILABLE,previewNotAvailableDesc:r.PREVIEW_NOT_AVAILABLE_DESC})),this._initWrappers(),i.set("preview_elem",this.$previewBody),i.get("standalone")&&(this.$homeBtn.hide(),this.$previewNameCn.removeClass("with-home-btn")),i.get("read_only")&&(this.$actionMenuBtn.hide(),this.$pluginsSelector.hide()),(n.noShare||!n.appApi.pluginsApi.isPluginAvailable("send"))&&this.$(".full-preview-send-btn").hide()),this._updateRendition(),this._updateName(),this._updateViewFormat(),this._updateShowRhp(),this._renderChildViews()},_initWrappers:function(){this.$homeBtn=this.$(".full-preview-home-btn"),this.$previewHeader=this.$(".full-preview-header"),this.$previewMain=this.$(".full-preview-main"),this.$previewBody=this.$(".full-preview-body"),this.$previewImageCn=this.$(".full-preview-image-container"),this.$previewImage=this.$(".full-preview-image.single"),this.$previewSvg=this.$(".full-preview-svg.single"),this.$noPreview=this.$(".full-preview-not-available"),this.$actionMenuBtn=this.$(".full-preview-action-menu-btn"),this.$actionMenu=this.$(".full-preview-action-menu"),this.$previewHud=this.$(".full-preview-hud"),this.$previewSidebar=this.$(".full-preview-sidebar"),this.$previewNameCn=this.$(".full-preview-name-container"),this.$previewName=this.$(".full-preview-name"),this.$headerBtns=this.$(".full-preview-header-btns"),this.$pluginsSelector=this.$(".full-preview-plugins-selector"),this.$pluginsContent=this.$(".full-preview-sidebar")},_open:function(){var e=this.$el;this._close(),this._isExpanded=!0,e.addClass("shown"),this.delegateEvents(this.viewEvents),this.options.appApi.windowApi.addWindowResizeCallback(this._onWindowResize),this.render()},_close:function(){var e=this.$el;if(!this._isExpanded)return;this._isExpanded=!1,this.options.appApi.windowApi.removeWindowResizeCallback(this._onWindowResize),this._isHeightEstimated=!1,this._removePluginsOverlayViews(),this.$previewImageCn.find(".full-preview-image-container.scroll-pages").remove(),this._removeBodyScrollEventListener();try{this.$(".full-preview-image").removeAttr("src"),this.$(".full-preview-svg").empty(),this._hasImage=!1,this._hasSvg=!1}catch(t){}this.$noPreview.hide(),e.removeClass("shown"),this.remove(),this.undelegateEvents(),delete this._commentMarkupRequiredCached},_getName:function(){var t,n;return n=this.options.fullPreviewUiModel.get("item_model"),n&&(t=e.Util.replaceSpaceWithNbsp(n.get("name"))),t||(t=""),t},_getNameAndControlsWidth:function(){var e=this.$el;return e.width()-o.getCssNum(this.$previewNameCn,"left")},_getNameAndGearWidth:function(){var e,t=this.$pluginsSelector;return e=this._getNameAndControlsWidth()-o.getFullWidth(this.$headerBtns),t.css("display")!=="none"&&(e-=o.getFullWidth(t)),e},_getNameWidth:function(){var e=this._getNameAndGearWidth()-o.getFullWidth(this.$actionMenuBtn);return e},_updateName:function(){var e=this.$previewNameCn,t=this.$previewName;e.width(this._getNameAndGearWidth()-o.getExtraWidth(e)),t.text(this._getName()),this._truncateName()},_truncateName:function(){function r(){return i.getTextSize(n).width-t}var t=this._getNameWidth(),n=this.$previewName;e.Locale.getLocale()==="ja-jp"&&(t*=.85,t=Math.floor(t)),!isNaN(t)&&t>0&&i.truncateToFit(n,r)},_gotRenditionLoadError:function(){this.options.fullPreviewUiModel.set("got_rendition_load_error",!0)},_updateRendition:function(){var t=this.options.fullPreviewUiModel;if(!t.get("page_count"))return;if(t.isScrollPagesView())this.$previewImageCn.find(".full-preview-image-container.scroll-pages").length===0&&this._createScrollPagesImages(),t.get("got_current_scroll_page")?this._getScrollPagesChunk():this._getScrollPagesCurrent();else{var n=e.Util;!this._isExpanded&&(n.isIE8()||n.isFirefox())?_.delay(this._getPageRendition,t.get("toggle_rhp_duration")):this._getPageRendition()}},_acknowledgePageLoading:function(e){var t=this.options.fullPreviewUiModel,n;t.isScrollPagesView()?(n=t.get("loaded_scroll_pages"),n||(n={}),_.has(n,e)||(n[e]=!0,t.set("loaded_scroll_pages",n),t.trigger("change:loaded_scroll_pages"))):t.set("loaded_fitandfull_page",e)},_adjustSvgDimensions:function(e){var t,n,r=this.options.fullPreviewUiModel.get("zoom_factor"),i,s=c;if(e.length===0||e.data("pageNum")===undefined)return;this._removeBodyScrollEventListener(),t=parseFloat(e.attr("width")),n=parseFloat(e.attr("height")),i=this._getAspectRatio(e.data("pageNum"),t,n),i>1?(n=Math.ceil(1/i*s*r),t=s*r):(t=Math.ceil(i*s*r),n=s*r),e.attr("width",t+"px").attr("height",n+"px"),this._addBodyScrollEventListener()},_adjustImgDimensions:function(e){var t,n,r=this.options.fullPreviewUiModel,i=r.get("zoom_factor"),s,o=c,u=1;if(e.length===0||!e.data("loaded")||e.data("pageNum")===undefined)return;t=parseFloat(e.width()),n=parseFloat(e.height());if(!r.isNGDocJobComplete()&&(t===0||n===0))return;e.data("currentZoom")&&(u=e.data("currentZoom")),this._removeBodyScrollEventListener(),s=this._getAspectRatio(e.data("pageNum"),t,n),s>1?(r.isNGDocJobComplete()||(o=t/u),n=Math.ceil(1/s*o*i),t=o*i):(r.isNGDocJobComplete()||(o=n/u),t=Math.ceil(s*o*i),n=o*i),e.width(t+"px").height(n+"px"),e.data("currentZoom",i),this._addBodyScrollEventListener()},_getAspectRatio:function(e,t,n){var r=this.options,i=r.fullPreviewUiModel,s=i.get("aspect_ratio_pages");return s[e]||(s[e]=t/n,i.set("aspect_ratio_pages",s,{silent:!0})),s[e]},_isScrollPageLoaded:function(e,t){var n=this.options.fullPreviewUiModel,r,i;return t?n.get("enable_ngdoc")?(i=this.$previewImageCn.find(".full-preview-image-container.scroll-pages").eq(e).find(".full-preview-svg.scroll-pages"),i.find(".full-preview-svg-content").length>0):!1:(r=n.get("loaded_scroll_pages"),r||(r={}),r[e])},_isScrollPageRequested:function(e,t){var n,r;return t?this.options.fullPreviewUiModel.get("enable_ngdoc")?(r=this.$previewImageCn.find(".full-preview-image-container.scroll-pages").eq(e).find(".full-preview-svg.scroll-pages"),r.data("is_loading")):!1:(n=this.$previewImageCn.find(".full-preview-image-container.scroll-pages").eq(e).find(".full-preview-image.scroll-pages"),!_.isUndefined(n.attr("src")))},_getPageRendition:function(){var e,t;e=this.options.fullPreviewUiModel,t=e.get("current_page");if(t===e.get("loaded_page"))return;e.set("loaded_page",t),this._hasImage=!1,this._hasSvg=!1,e.isNGDocView()?(this.$previewSvg.data({pageNum:undefined}),this.$previewSvg.fadeOut(_.bind(function(t){t===e.get("current_page")&&this._loadPageRendition()},this,t))):(this.$previewImage.data({loaded:!1,pageNum:undefined}),this.$previewImage.fadeOut(_.bind(function(t){t===e.get("current_page")&&this._loadPageRendition()},this,t)))},_loadPageRendition:function(){function u(t){var n=this.$previewSvg.find("svg"),r,i;t.isSVG?(n.length>0&&!n.hasClass("full-preview-svg-content")&&(n.attr("class","full-preview-svg-content"),n.data("pageNum",t.pageNum),this._adjustSvgDimensions(n)),r=!0):(i=!0,this.$previewImage.data("pageNum",t.pageNum),e.get("zoom_factor")!==1&&this._adjustImgDimensions(this.$previewImage)),t.pageNum===e.get("current_page")&&this._show(i,r)}function a(t){var n,r;LOG(0,"AcFiles.FullPreviewView._loadPageRendition: error"),t.isSVG?n=!1:r=!1,t.pageNum===e.get("current_page")&&this._show(r,n),this._gotRenditionLoadError()}var e,t,n,r,i,o;e=this.options.fullPreviewUiModel,t=e.get("item_model"),i=e.get("enable_ngdoc");if(!t)return;i&&e.isNGDocJobComplete()&&(r=t.getNGDocUrl(e.get("current_page")),this.$previewSvg.data("svg_url",r),f.loadSvg(this.$previewSvg,r,{pageNum:e.get("current_page"),isSVG:!0},!0).then(_.bind(u,this),_.bind(a,this))),o=this._isCommentMarkupRequired(),n=t.getRenditionUrl("preview",e.get("current_page"),o),s.loadImage(this.$previewImage,n,{pageNum:e.get("current_page"),isSVG:!1},!0).then(_.bind(u,this),_.bind(a,this))},_createScrollPagesImages:function(){var e=this.options.fullPreviewUiModel,t,n,r,i,s,o=e.get("enable_ngdoc");for(t=0,n=e.get("page_count");t0&&(s.addClass("subsequent-page"),r.addClass("subsequent-page"),o&&i.addClass("subsequent-page")),s.append(r),o&&s.append(i),this.$previewImageCn.append(s),t===n-1&&(s.addClass("last-page"),r.addClass("last-page"),o&&i.addClass("last-page"))},_onScrollPageContentLoad:function(e){var t=this.options.fullPreviewUiModel;this._isScrollPageLoaded(e)&&t.isNGDocView()&&this._isScrollPageLoaded(e,!0)&&t.set({got_current_scroll_page:!0}),e=t.get("current_page"),this._setScrollPagesScrollPosition(e),this._acknowledgePageLoading(e),this._getScrollPagesChunk(),this._renderPluginsOverlayViews(this.options)},_getScrollPagesCurrent:function(){function c(t){var n=t.$svgElement,i=t.$imgElement,s,o,u;this.$previewBody.removeClass("no-preview"),this.$noPreview.hide(),t.isSVG?(s=n.find("svg"),s.length>0&&(s.hasClass("full-preview-svg-content")||(s.attr("class","full-preview-svg-content"),s.data("pageNum",t.pageNum),this._adjustSvgDimensions(s)),o=parseFloat(s.attr("width")),u=parseFloat(s.attr("height")),n.width("auto").height("auto"),n.css("max-height","none"),this._updateViewFormat(),e.isNGDocView()&&(this._estimateScrollPagesHeights(o,u),this._onScrollPageContentLoad(t.pageNum)))):(i.show(),o=i.width(),u=i.height(),this._removeBodyScrollEventListener(),i.width("auto").height("auto"),i.css("max-height","none"),this._addBodyScrollEventListener(),r.data("pageNum",t.pageNum),e.get("zoom_factor")!==1&&this._adjustImgDimensions(i),this._updateViewFormat(),e.isNGDocView()&&n.find(".full-preview-svg-content").length>0?i.hide():(i.show(),this._estimateScrollPagesHeights(o,u),this._onScrollPageContentLoad(t.pageNum)))}function h(n){var r;t=e.get("current_page"),n.isSVG||(n.$imgElement.removeAttr("src"),n.pageNum===t&&!this._isScrollPageLoaded(n.pageNum,!0)&&(r=!0)),r&&this._showScrollPageError(),this._gotRenditionLoadError()}var e=this.options.fullPreviewUiModel,t,n,r,i,o,u,a=e.get("enable_ngdoc"),l;t=e.get("current_page"),n=e.get("item_model"),r=this.$previewImageCn.find(".full-preview-image-container.scroll-pages").eq(t).find(".full-preview-image.scroll-pages"),this._isScrollPageLoaded(t)?r.show():r.hide(),a&&(i=this.$previewImageCn.find(".full-preview-image-container.scroll-pages").eq(t).find(".full-preview-svg.scroll-pages")),a&&e.isNGDocJobComplete()&&!this._isScrollPageRequested(t,!0)&&!this._isScrollPageLoaded(t,!0)&&(u=n.getNGDocUrl(t),f.loadSvg(i,u,{$svgElement:i,$imgElement:r,pageNum:t,isSVG:!0}).then(_.bind(c,this),_.bind(h,this))),!this._isScrollPageRequested(t)&&!this._isScrollPageLoaded(t)&&(l=this._isCommentMarkupRequired(),o=n.getRenditionUrl("preview",t,l),s.loadImage(r,o,{$imgElement:r,$svgElement:i,pageNum:t,isSVG:!1}).then(_.bind(c,this),_.bind(h,this)))},_getScrollPagesChunk:function(){var e,t,n,r,i,o,u,a,l,c,h,p=[],d,v;e=this.options.fullPreviewUiModel,t=e.get("item_model"),n=e.get("page_count"),r=e.get("current_page"),i=e.get("scroll_pages_chunk"),d=e.get("enable_ngdoc");if(!n)return;o=Math.max(Math.ceil(r-i/2),0),u=Math.min(o+i,n-1),l=this.$previewImageCn.find(".full-preview-image-container.scroll-pages"),v=this._isCommentMarkupRequired();for(a=o;a<=u;a+=1)c=l.eq(a).find(".full-preview-image.scroll-pages"),d&&e.isNGDocJobComplete()&&(h=l.eq(a).find(".full-preview-svg.scroll-pages"),!this._isScrollPageRequested(a,!0)&&!this._isScrollPageLoaded(a,!0)&&p.push(f.loadSvg(h,t.getNGDocUrl(a),{$svgElement:h,$imgElement:c,pageNum:a,isSVG:!0}))),!this._isScrollPageRequested(a)&&!this._isScrollPageLoaded(a)&&p.push(s.loadImage(c,t.getRenditionUrl("preview",a,v),{$svgElement:h,$imgElement:c,pageNum:a,isSVG:!1}));_.each(p,_.bind(function(t){t.then(_.bind(function(t){var n;h=t.$svgElement,c=t.$imgElement,t.isSVG?(n=h.find("svg"),n.length>0&&(n.hasClass("full-preview-svg-content")||(n.attr("class","full-preview-svg-content"),n.data("pageNum",t.pageNum),this._adjustSvgDimensions(n)),h.width("auto").height("auto"),h.css("max-height","none"))):(this._removeBodyScrollEventListener(),c.width("auto").height("auto"),c.css("max-height","none"),this._addBodyScrollEventListener(),c.data("pageNum",t.pageNum),e.get("zoom_factor")!==1&&this._adjustImgDimensions(c)),this._acknowledgePageLoading(t.pageNum)},this),function(e){e.isSVG||e.$imgElement.removeAttr("src"),LOG("AcFiles.FullPreviewView._onScrollPagesRenditionError pageNum="+e.pageNum)})},this)),$.when.apply(undefined,p).then(_.bind(function(){_.defer(_.bind(function(){this._renderPluginsOverlayViews(this.options),this._updateViewFormat()},this))},this),_.bind(function(){this._gotRenditionLoadError()},this))},_estimateScrollPagesHeights:function(e,t){var n,r,i,s,u,a,f,l=this.options.fullPreviewUiModel,c=l.get("enable_ngdoc");if(!e||!t||this._isHeightEstimated)return;i=this.$previewImageCn.find(".full-preview-image-container.scroll-pages");for(n=0,r=l.get("page_count");n0&&w.css("max-height",b+"px");if(u){s.css({"max-width":y+"px","max-height":b+"px",display:"inline-block"}),s.find(".full-preview-svg-content").css({"max-width":y+"px","max-height":b+"px",display:"inline-block"});for(m=p;m<=d;m+=1)f=s.eq(m),l=f.find(".full-preview-svg-content"),c=i.eq(m),l.length>0&&(b=y/this._getAspectRatio(m,parseFloat(l.attr("width")),parseFloat(l.attr("height"))),l.css("max-height",b+"px"),f.css("max-height",b+"px"),c.css("max-height",b+"px"));s.removeClass("hidden"),i.addClass("hidden");for(m=p;m<=d;m+=1)f=s.eq(m),l=f.find(".full-preview-svg-content"),l.length===0&&(i.eq(m).removeClass("hidden"),f.addClass("hidden"))}else{a&&s.addClass("hidden"),i.removeClass("hidden");for(m=p;m<=d;m+=1)c=i.eq(m),c.data("loaded")&&(b=y/this._getAspectRatio(m,c.width(),c.height()),c.css("max-height",b+"px"))}this._isHeightEstimated&&this._setScrollPagesScrollPosition(h),this._addBodyScrollEventListener()}else o.addClass("hidden"),i.addClass("hidden"),a&&s.addClass("hidden"),u?this._hasSvg?(this.$previewImage.addClass("hidden"),this.$previewSvg.removeClass("hidden")):this._hasImage&&(this.$previewImage.removeClass("hidden"),this.$previewSvg.addClass("hidden")):this._hasImage&&(this.$previewSvg.addClass("hidden"),this.$previewImage.removeClass("hidden")),l=this.$previewSvg.find(".full-preview-svg-content"),e.isFitPageWidthView()?(y=(n-t-r*2)*e.get("zoom_factor"),l.length>0?(b=y/this._getAspectRatio(h,parseFloat(l.attr("width")),parseFloat(l.attr("height"))),l.css({"max-width":y+"px","max-height":b+"px"}),this.$previewSvg.css({"max-width":y+"px","max-height":b+"px"})):b=y/this._getAspectRatio(h,this.$previewImage.width(),this.$previewImage.height()),this.$previewImage.css({"max-width":y+"px","max-height":b+"px"})):(b=(this.$previewBody.height()-r)*e.get("zoom_factor"),l.length>0?(y=b*this._getAspectRatio(h,parseFloat(l.attr("width")),parseFloat(l.attr("height"))),l.css({"max-width":y+"px","max-height":b+"px"}),this.$previewSvg.css({"max-width":y+"px","max-height":b+"px"})):y=b*this._getAspectRatio(h,this.$previewImage.width(),this.$previewImage.height()),this.$previewImage.css({"max-width":y+"px","max-height":b+"px"})),this.$previewBody.scrollTop(0)},_addBodyScrollEventListener:function(){var e=this.options.fullPreviewUiModel.get("scroll_debounce_delay");this._allowBodyScrollEventListener=!0,this.$previewBody.off("scroll").on("scroll",_.debounce(this._onBodyScroll,e))},_removeBodyScrollEventListener:function(){this._allowBodyScrollEventListener=!1,this.$previewBody.off("scroll")},_onBodyScroll:function(){var e,t,n,r,i,s,u,a,f,l,c,h,p;if(!this._allowBodyScrollEventListener)return;e=this.$previewBody.scrollTop(),t=e+this.$previewBody.height(),n=this.$previewImageCn.find(".full-preview-image-container.scroll-pages"),r=1,u=this.options.fullPreviewUiModel;for(i=0,s=u.get("page_count");i=e||i>=s-1){p=i;break}f=n.eq(i+1),h=c+a.height()+o.getCssNum(f,"margin-top")+r;if(h>t){p=i;break}}_.isUndefined(p)||u.set({current_page:p,align_current_page:!1})},_setScrollPagesScrollPosition:function(e){var t=this.$previewBody,n,r,i;n=this.$previewImageCn.find(".full-preview-image-container.scroll-pages").eq(e),r=n.position(),r&&(i=r.top,this.options.fullPreviewUiModel.get("align_current_page")&&(this._removeBodyScrollEventListener(),t.scrollTop(i+o.getCssNum(n,"margin-top")),this._addBodyScrollEventListener()))},_updateShowRhp:function(){this.options.fullPreviewUiModel.get("show_rhp")?(this.$previewMain.removeClass("full-screen"),this.$previewSidebar.removeClass("hide-rhp")):(this.$previewMain.addClass("full-screen"),this.$previewSidebar.addClass("hide-rhp"))},_areOverlaysEnabled:function(){var e=this.options,t=e.fullPreviewOverlaysUiModel,n=t.get("plugins"),r,i;if(n.length===0)return!1;for(i=0;i0)break}return i===n.length?!1:!0},_renderChildViews:function(){var e=this.options,t=e.appApi.pluginsApi,n,r=e.fullPreviewUiModel;n=t.hasPluginType("full_preview_rhp"),this._renderHomeBtnView(),this._renderMenuView(),this._renderHudView(),e=_.extend({},this.options,{pluginsUiModel:n?e.fullPreviewRhpPluginsUiModel:e.fullPreviewPluginsUiModel}),this._renderPluginsContentView(e),this._renderPluginsOverlayViews(e),n?this.$pluginsSelector.hide():this._renderPluginsSelectorView(e),r.isNGDocView()&&r.isNGDocJobComplete()&&this._areOverlaysEnabled()?(this.$(".full-preview-svg").on("mousemove",this._onMouseMove),this.$(".full-preview-image").on("mousemove",this._onMouseMove),this.$(".full-preview-overlay-content").on("mousemove",this._onMouseMove)):(this.$(".full-preview-svg").off("mousemove"),this.$(".full-preview-image").off("mousemove"),this.$(".full-preview-overlay-content").off("mousemove"))},_renderHomeBtnView:function(){this._renderChildView("_fullPreviewHomeBtnView",t.FullPreviewHomeBtnView,this.$homeBtn)},_renderMenuView:function(){this._renderChildView("_fullPreviewActionMenuView",t.FullPreviewActionMenuView,this.$actionMenu,{$actionMenuBtn:this.$actionMenuBtn})},_renderHudView:function(){this._renderChildView("_fullPreviewHudView",t.FullPreviewHudView,this.$previewHud)},_renderPluginsContentView:function(e){this._renderChildView("_pluginsContentView",t.FullPreviewPluginsContentView,this.$pluginsContent,e)},_renderPluginsOverlayViews:function(e){var n,r,i;if(!this._areOverlaysEnabled())return;i=this.$previewImageCn.find(".full-preview-image-container.scroll-pages");for(n=0;n
'}),define("files/dev/templates/search-results-template",[],function(){return'
'}),define("files/dev/views/search-results-summary-view",["core/ac-core","files/ac-files","i18n!files/nls/ui-strings","core/views/view"],function(e,t,n){return t.SearchResultsSummaryView=e.View.extend({initialize:function(){e.View.prototype.initialize.call(this),this._addModelEventListeners(),this._addUiModelEventListeners()},render:function(){return e.View.prototype.render.call(this),this.$el.text(this._getSummary()),this},_getSummary:function(){var e,t=this.options.searchUiModel;return t.get("invalid")?e=n.SEARCH_RESULTS:e=this._getStatusSummary(t.get("status")),e},_getStatusSummary:function(t){var r=this.options,i,s;switch(t){case e.SearchUiModel.STATUS_PENDING:i=n.SEARCH_RESULTS;break;case e.SearchUiModel.STATUS_SUCCEEDED:s=r.collectionUiModel.get("item_count"),_.isUndefined(s)?i=n.SEARCH_RESULTS:i=_.template(n.SEARCH_RESULTS_COUNT,{count:s});break;case e.SearchUiModel.STATUS_FAILED:i=n.SEARCH_RESULTS_UNAVAILABLE;break;default:i=""}return i},_addModelEventListeners:function(){var e=this.options.searchModel.get("items");e.on("all",this._onItemsChange)},_onItemsChange:function(){this.render()},_addUiModelEventListeners:function(){var e=this.options,t;t=e.searchUiModel,t.on("change:status",this._onStatusChange),t.on("change:invalid",this._onInvalidChange),t=e.collectionUiModel,t.on("change:item_count",this._onItemCountChange)},_onStatusChange:function(){this.render()},_onInvalidChange:function(e,t){t&&this.render()},_onItemCountChange:function(e,t){var n=this.options.searchUiModel;n.isSearchPending()?e.unset("item_count",{silent:!0}):n.hasSearchSucceeded()&&this.render()}}),t.SearchResultsSummaryView}),define("files/dev/templates/no-search-results-template",[],function(){return'
<%= noSearchResultsInFolder %>
'}),define("files/dev/views/no-search-results-view",["core/ac-core","files/ac-files","core/utils/util","files/templates/no-search-results-template","i18n!files/nls/ui-strings","core/views/view"],function(e,t,n,r,i){return t.NoSearchResultsView=e.View.extend({initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(r),this._addUiModelEventListeners()},render:function(){e.View.prototype.render.call(this),this.$el.children().length===0&&(this.$el.html(this._template({noSearchResults:i.NO_SEARCH_RESULTS,tryDifferentSearch:i.TRY_DIFFERENT_SEARCH,noSearchResultsInFolder:i.NO_SEARCH_RESULTS_FOLDER})),this._initWrappers()),this.options.appApi.selectionApi.isRunningInFileSelection()||n.isCEF()&&this.options.appApi.saveAsApi.isRunningInFileSaveAs()||(this.$(".title-search").text(i.NO_SEARCH_RESULTS_VIRGO),this.$(".subtitle-search").text(i.TRY_DIFFERENT_SEARCH_VIRGO))},_initWrappers:function(){this.$instructionTextFolder=this.$(".instruction-text-folder"),this.$instructionText=this.$(".instruction-text").not(".instruction-text-folder")},_addUiModelEventListeners:function(){var e=this.options.collectionUiModel;e.on("change:show_empty",this._onShowEmptyChange)},_onShowEmptyChange:function(e,t){var r=this.options,s=r.searchUiModel;if(t){if(s.isSearchClosed()||s.isSearchPending())return;this.render(),this.$el.addClass("shown"),s.showFolders()?(this.$instructionTextFolder.show(),this.$instructionText.hide()):(this.$instructionTextFolder.hide(),this.$instructionText.show()),n.isCEF()&&r.appApi.saveAsApi.isRunningInFileSaveAs()?this.$instructionTextFolder.text(i.NO_FILES_IN_FOLDER):this.$instructionTextFolder.text(i.NO_SEARCH_RESULTS_FOLDER)}else this.$el.removeClass("shown")}}),t.NoSearchResultsView}),define("files/dev/templates/search-message-template",[],function(){return'
'}),define("files/dev/views/search-message-view",["core/ac-core","files/ac-files","files/templates/search-message-template","i18n!files/nls/ui-strings","core/views/view"],function(e,t,n,r){return t.SearchMessageView=e.View.extend({initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(n),this._addUiModelEventListeners()},render:function(){var t=this.$el,n;e.View.prototype.render.call(this),t.children().length===0&&(t.html(this._template()),this._initWrappers()),n=this._getUserMessageObj(),_.isEmpty(n)?t.removeClass("shown"):(this.$instructionText.text(n.header),this.$instructionSubtext.text(n.message),t.addClass("shown"))},_initWrappers:function(){this.$instructionText=this.$(".instruction-text"),this.$instructionSubtext=this.$(".instruction-text.sub-text")},_getUserMessageObj:function(){var e=this.options.searchUiModel,t={};return e.get("too_many_query_boxes")&&(t.header=r.TOO_MANY_SEARCH_TERMS_HEADER,t.message=r.TOO_MANY_SEARCH_TERMS_MESSAGE),t},_addUiModelEventListeners:function(){this.listenTo(this.options.searchUiModel,"change:too_many_query_boxes",this._onTooManyQueryBoxesChange)},_onTooManyQueryBoxesChange:function(){this.render()}}),t.SearchMessageView}),define("files/dev/views/search-results-view",["core/ac-core","files/ac-files","files/templates/search-results-template","core/utils/util","core/utils/view-util","files/views/folder-navigation-view","files/views/search-results-summary-view","core/views/view","core/views/collection-view","files/views/no-search-results-view","files/views/search-message-view"],function(e,t,n,r,i){return t.SearchResultsView=e.View.extend({initialize:function(){e.View.prototype.initialize.call(this),this._addUiModelEventListeners()},render:function(){var t=this.$el;e.View.prototype.render.call(this),t.children().length===0&&(t.html(_.template(n)({viewId:this.options.viewId})),this._initWrappers(),i.setElementFontByLocale(this.$el,"div")),this._renderChildViews(),this._updateFolderNavigationView();if(!this.options.appApi.saveAsApi.isRunningInFileSaveAs()&&!this.options.appApi.selectionApi.isRunningInFileSelection()){var r=this.options.appApi.connectorsApi.getConnectorPluginName(this.options.pluginId);r==="root"&&this.$items.attr("id","dcFolderSearchItems"),r==="ccloud"&&this.$items.attr("id","ccFolderSearchItems"),this.options.pluginId==="scan_files"&&this.$items.attr("id","scanFolderSearchItems")}return this},_initWrappers:function(){this.$folderNavigation=this.$(".folder-navigation").not(".files-search-results-summary"),this.$summary=this.$(".files-search-results-summary"),this.$items=this.$(".files-search-results-items"),this.$noResults=this.$(".files-no-search-results"),this.$message=this.$(".files-search-message"),this.options.isInSearchResultsView&&this.$items.addClass("uss-search-active")},_getCollectionUiModel:function(){var t;return this._collectionUiModel||(t=this._collectionUiModel=e.uiModelFactory.create("CollectionUiModel"),this.options.searchUiModel.showFolders()||t.set({is_item_excluded:function(e){return e.isFolder()}})),this._collectionUiModel},_renderChildViews:function(){var e=this._getCollectionUiModel();this._renderFolderNavigationView(e),this._renderSummaryView(e),this._renderNoResultsView(e),this._renderItemsView(e),this._renderMessageView()},_renderFolderNavigationView:function(e){this._renderChildView("_folderNavigationView",t.FolderNavigationView,this.$folderNavigation,{collectionUiModel:e})},_renderSummaryView:function(e){this._renderChildView("_summaryView",t.SearchResultsSummaryView,this.$summary,{collectionUiModel:e})},_renderItemsView:function(t){this._renderChildView("_itemsView",e.CollectionView,this.$items,{collection:this.options.searchModel.get("items"),collectionUiModel:t})},_renderNoResultsView:function(e){this._renderChildView("_noResultsView",t.NoSearchResultsView,this.$noResults,{collectionUiModel:e})},_renderMessageView:function(){this._renderChildView("_messageView",t.SearchMessageView,this.$message)},_updateFolderNavigationView:function(){var e=this.options,t=e.searchUiModel,n=this.$folderNavigation,i=this.$items,s=this.$("#virgoNavigation");if(this.options.appApi.selectionApi.isRunningInFileSelection()||r.isCEF()&&this.options.appApi.saveAsApi.isRunningInFileSaveAs())t.get("current_folder_id")!==e.appApi.folderApi.getRootFolderId(e.pluginId)&&t.showFolders()||t.showNavigationAtRoot()?(n.addClass("shown"),i.addClass("with-folder-navigation")):(n.removeClass("shown"),i.removeClass("with-folder-navigation"));else{var o=this.options.appApi.connectorsApi.getConnectorPluginName(e.pluginId),u="";o==="root"&&(u="with-virgo-dc-folder-navigation"),o==="ccloud"&&(u="with-virgo-cc-folder-navigation"),e.pluginId==="scan_files"&&(u="with-virgo-scan-folder-navigation"),s.hasClass("shown")?i.removeClass(u):i.addClass(u)}},_addUiModelEventListeners:function(){var e=this.options,t=e.searchModel,n=e.searchUiModel;r.isCEF()&&e.appApi.sessionApi.addSignedInChangeCallback(function(e,n){n||t.get("items").reset()}),this.listenTo(n,"change:status",this._onSearchStatusChange)},_onSearchStatusChange:function(e,t){var n=e.isSearching();this._getCollectionUiModel().set("is_active",n),n&&this.render()}}),t.SearchResultsView}),define("files/dev/views/files-body-view",["core/ac-core","files/ac-files","files/templates/files-body-template","core/views/view","core/views/hover-preview-view","files/views/folder-view","files/views/search-results-view","core/views/custom-range-selector-view"],function(e,t,n){return t.FilesBodyView=e.View.extend({initialize:function(){e.View.prototype.initialize.call(this),this._addUiModelEventListeners()},render:function(){return e.View.prototype.render.call(this),this.$el.children().length===0&&(this.$el.html(_.template(n)),this._initWrappers()),this._renderChildViews(),this},_initWrappers:function(){this.$filesLists=this.$(".files-list"),this.$folder=this.$(".folder"),this.$searchResults=this.$(".files-search-results"),this.options.isInSearchResultsView&&(this.$searchResults.addClass("uss-search-active"),this.$el.addClass("uss-search-active")),this.options.noHoverPreview||(this.$hoverPreview=this.$(".hover-preview"))},_renderChildViews:function(){var e=this.options,t=this.$folder,n=this.$searchResults;e.noHoverPreview||this._renderHoverPreviewView(),e.filesUiModel.isFolderView()?(n.addClass("hidden"),t.removeClass("hidden"),this._renderFolderView()):(t.addClass("hidden"),n.removeClass("hidden"),this._renderSearchResultsView())},_renderHoverPreviewView:function(){this._renderChildView("_hoverPreviewView",e.HoverPreviewView,this.$hoverPreview)},_renderFolderView:function(){this._renderChildView("_folderView",t.FolderView,this.$folder,{hoverPreviewView:this._hoverPreviewView})},_renderSearchResultsView:function(){this._renderChildView("_searchResultsView",t.SearchResultsView,this.$searchResults,{hoverPreviewView:this._hoverPreviewView})},_addUiModelEventListeners:function(){this.listenTo(this.options.filesUiModel,"change:view",this._onViewChange)},_onViewChange:function(e,n){var r=this.$folder,i=this.$searchResults,s=this.render,o=n===t.FilesUiModel.VIEW_FOLDER;r.stop(!0,!0),i.stop(!0,!0),o?i.fadeOut(function(){r.removeClass("hidden"),r.animate({opacity:1},s)}):r.animate({opacity:0},function(){r.addClass("hidden"),i.fadeIn(s)})}}),t.FilesBodyView}),define("files/dev/templates/files-ipm-template",[],function(){return'
<%= ipm %>
'}),define("files/dev/views/files-ipm-view",["core/ac-core","files/ac-files","files/templates/files-ipm-template","core/views/view"],function(e,t,n){return t.FilesIpmView=e.View.extend({events:{"click .files-ipm-link-btn":"_onLinkButtonClick"},initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(n)},render:function(){var t=this.$el,n,r,i=this.options,s=i.pluginId,o,u,a,f,l=i.appApi.pluginsApi,c=i.appApi.connectorsApi;return e.View.prototype.render.call(this),t.children().length===0&&(u=c.isConnectorPlugin(s),u&&(o=l.getPluginUiModel(s).get("connector_name"),n=c.getConnectorsUiHelpers(o),a=n.add_ui,a&&(f=_.unescape(a.add_html),r=a.add_button_label,t.html(this._template({ipm:f,link:r}))))),this},_onLinkButtonClick:function(){var e=this.options;e.appApi.connectorsApi.addConnector(e.pluginId)}}),t.FilesIpmView}),define("files/dev/templates/files-container-template",[],function(){return'
'}),define("files/dev/templates/files-template",[],function(){return'
'}),define("files/dev/templates/virgo-files-header-template",[],function(){return'
'}),define("files/dev/templates/virgo-folder-navigation-template",[],function(){return'
'}),define("files/dev/views/virgo-folder-navigation-view",["core/ac-core","files/ac-files","files/templates/virgo-folder-navigation-template","i18n!core/nls/ui-strings","i18n!files/nls/ui-strings","core/utils/util","core/utils/breadcrumbs","core/utils/css-util","core/utils/truncate","core/utils/sc-analytics","core/views/view"],function(e,t,n,r,i,s,o,u,a,f){return t.VirgoFolderNavigationView=e.View.extend({events:{},initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(n),this._addUiModelEventListeners()},render:function(){var t=this.options;e.View.prototype.render.call(this),this.$el.children().length===0&&(this.$el.html(this._template({viewId:t.viewId})),this._initWrappers(),s.isCEF()&&t.appApi.saveAsApi.isRunningInFileSaveAs()&&this.$path.addClass("folder-path-save-as"));if(this.options.searchMode==="on"){var n="";if(this.options.pluginId==="scan_files")n=i.VIRGO_SCANS;else{var r=this.options.appApi.connectorsApi.getConnectorPluginName(t.pluginId);r==="root"?n=i.VIRGO_DOCUMENT_CLOUD:r==="ccloud"&&(n=i.VIRGO_CREATIVE_CLOUD)}var o=this.options.folderUiModel.get("path"),u=o.length;for(var a=0;a0&&this._clearFolderNavigationPath();if(!e.searchUiModel.showFolders()&&!e.showNavigationAtRoot)return;t&&o.isRunningInFileSaveAs()&&n.addClass("no-back-btn")}else t&&o.isRunningInFileSaveAs()&&n.removeClass("no-back-btn");this._useBreadcrumbs()?e.pluginId==="scan_files"&&i<=1||(e.pluginId==="scan_files"&&r[0].name==="/"&&i===2?(r.shift(),this._showScanBreadcrumbs(r)):(e.pluginId==="scan_files"&&i>=2&&r[0].name==="/"&&r.shift(),this._showBreadcrumbs(r))):this._showFolderName(r[i-1].name)},_clearFolderNavigationPath:function(){this.$path.empty()},_showScanBreadcrumbs:function(n){var r=this.options,a=r.appApi,l=this.$el,c=this.$path,h,p;p=_.bind(function(n){this._logSiteCatalystEvent([f.BREADCRUMB,n===a.folderApi.getRootFolderId(r.pluginId)?f.HOME:"",f.CLICKED]),r.searchUiModel.showFolders()?(r.selectionUiModel.clearSelection(),this._triggerViewEvent(e.ViewEvents.SEARCH_IN_FOLDER,{search_folder_id:n})):this._triggerViewEvent(t.ViewEvents.NAVIGATE_TO_FOLDER,{id:n})},this),h=l.parent().width()-u.getExtraWidth(c),h>=700?h-=500:h=200,s.isCEF()&&a.saveAsApi.isRunningInFileSaveAs()&&(h=h),r.pluginId==="scan_files"&&o.display(n,c,h,p,e.Locale.getLocale(),i.VIRGO_SCANS)},_showFolderBreadcrumbs:function(n,r){var i=this.options,a=i.appApi,l=this.$el,c=this.$path,h,p;p=_.bind(function(n){this._logSiteCatalystEvent([f.BREADCRUMB,n===a.folderApi.getRootFolderId(i.pluginId)?f.HOME:"",f.CLICKED]),i.searchUiModel.showFolders()?(i.selectionUiModel.clearSelection(),this._triggerViewEvent(e.ViewEvents.SEARCH_IN_FOLDER,{search_folder_id:n})):this._triggerViewEvent(t.ViewEvents.NAVIGATE_TO_FOLDER,{id:n})},this),h=l.parent().width()-u.getExtraWidth(c),h>=700?h-=500:h=200,s.isCEF()&&a.saveAsApi.isRunningInFileSaveAs()&&(h=h),o.display(n,c,h,p,e.Locale.getLocale(),r)},_showBreadcrumbs:function(n){var a=this.options,l=a.appApi,c=this.$el,h=this.$path,p,d;d=_.bind(function(n){this._logSiteCatalystEvent([f.BREADCRUMB,n===l.folderApi.getRootFolderId(a.pluginId)?f.HOME:"",f.CLICKED]),a.searchUiModel.showFolders()?(a.selectionUiModel.clearSelection(),this._triggerViewEvent(e.ViewEvents.SEARCH_IN_FOLDER,{search_folder_id:n})):this._triggerViewEvent(t.ViewEvents.NAVIGATE_TO_FOLDER,{id:n})},this),p=c.parent().width()-u.getExtraWidth(h),p>=700?p-=500:p=200,s.isCEF()&&l.saveAsApi.isRunningInFileSaveAs()&&(p=p);if(a.pluginId==="scan_files")o.display(n,h,p,d,e.Locale.getLocale(),i.VIRGO_SCANS);else{var v=this.options.appApi.connectorsApi.getConnectorPluginName(a.pluginId);v==="root"?o.display(n,h,p,d,e.Locale.getLocale(),i.VIRGO_DOCUMENT_CLOUD):v==="ccloud"?o.display(n,h,p,d,e.Locale.getLocale(),i.VIRGO_CREATIVE_CLOUD):v==="desktop_sharepoint"?o.display(n,h,p,d,e.Locale.getLocale(),i.VIRGO_SHAREPOINT):v==="dropbox"?o.display(n,h,p,d,e.Locale.getLocale(),i.VIRGO_DROPBOX):v==="googleDrive"?o.display(n,h,p,d,e.Locale.getLocale(),i.VIRGO_GOOGLE_DRIVE):v==="box"?o.display(n,h,p,d,e.Locale.getLocale(),i.VIRGO_BOX):v==="onedrive"||v==="onedrivebusiness"?o.display(n,h,p,d,e.Locale.getLocale(),i.VIRGO_ONEDRIVE):o.display(n,h,p,d,e.Locale.getLocale(),r.HOME)}},_showFolderName:function(e){var t=this.$el,n=this.$path,r;n.text(e),r=t.parent().width()-u.getCssNum(n,"left")-u.getCssNum(n,"margin-right"),a.truncateElementText(n,r)},_onBackButtonClick:function(){var n=this.options,r=n.folderModel,i;this._logSiteCatalystEvent([f.BREADCRUMB,f.BACK,f.CLICKED]);if(n.searchUiModel.showFolders()){i=n.folderUiModel.get("path");if(i.length>1||n.pluginId==="scan_files"&&i.length>2&&i[0].name==="/")this.options.selectionUiModel.clearSelection(),this._triggerViewEvent(e.ViewEvents.SEARCH_IN_FOLDER,{search_folder_id:i[i.length-2].id})}else n.collectionsUiModel.set("scroll_id_into_view",r.get("id")),this._triggerViewEvent(t.ViewEvents.NAVIGATE_TO_FOLDER,{id:r.get("parent_id")})},_addUiModelEventListeners:function(){var e=this.options,t=e.searchUiModel;this.options.folderUiModel.on("change:path",this._onFolderPathChange),this.listenTo(t,"change:status",this._onSearchStatusChange)},_onSearchStatusChange:function(){this.options.searchUiModel.isSearching()?this.options.searchMode="on":this.options.searchMode="off",this.render()},_onFolderPathChange:function(){this.render()}}),t.VirgoFolderNavigationView}),define("files/dev/templates/virgo-filter-navigation-template",[],function(){return'
'}),define("files/dev/templates/virgo-filter-date-menu-template",[],function(){return'
<%= withinLastWeek %>
<%= withinLastMonth %>
<%= pastYear %>
'}),define("files/dev/views/virgo-filter-date-menu-view",["files/ac-files","files/templates/virgo-filter-date-menu-template","i18n!core/nls/ui-strings","files/views/filter-submenu-view"],function(e,t,n){return e.VirgoFilterDateMenuView=e.FilterSubmenuView.extend({render:function(){var r=this.$el;return e.FilterSubmenuView.prototype.render.call(this),r.children().length===0&&r.html(_.template(t)({anyTime:n.VIRGO_ANY_TIME,pastHour:n.VIRGO_VIRGO_PAST_HOUR,custom:n.CUSTOM,today:n.VIRGO_Past_24_HOUR,withinLastWeek:n.VIRGO_PAST_WEEK,withinLastMonth:n.VIRGO_PAST_MONTH,pastYear:n.VIRGO_PAST_YEAR})),this}}),e.VirgoFilterDateMenuView}),define("files/dev/templates/virgo-filter-file-type-menu-template",[],function(){return'
data-site-catalyst="AnyType" role="menuitem" tabindex="-1"> <%= anyTypeUiName %>
data-site-catalyst="PDF" role="button" tabindex="-1"> <%= pdfUiName %>
data-site-catalyst="Image" role="button" tabindex="-1"> <%= imageUiName %>
data-site-catalyst="HTML" role="button" tabindex="-1"> <%= htmlUiName %>
data-site-catalyst="Word" role="button" tabindex="-1"> <%= wordUiName %>
data-site-catalyst="Excel" role="button" tabindex="-1"> <%= excelUiName %>
data-site-catalyst="Powerpoint" role="button" tabindex="-1"> <%= powerpointUiName %>
data-site-catalyst="Text" role="button" tabindex="-1"> <%= textUiName %>
data-site-catalyst="Video" role="button" tabindex="-1"> <%= videoUiName %>
data-site-catalyst="Zip" role="button" tabindex="-1"> <%= zipUiName %>
'}),define("files/dev/views/virgo-filter-file-type-menu-view",["files/ac-files","files/templates/virgo-filter-file-type-menu-template","i18n!core/nls/ui-strings","core/utils/file-types","files/views/filter-submenu-view"],function(e,t,n,r){return e.VirgoFilterFileTypeMenuView=e.FilterSubmenuView.extend({render:function(){var i=this.$el,s=r.MimeType,o=r.UiName;return e.FilterSubmenuView.prototype.render.call(this),i.children().length===0&&i.html(_.template(t)({anyTypeUiName:n.VIRGO_ANY_TYPE,anyTypeMimeType:n.VIRGO_ANY_TYPE,fillsignMimeType:s.ADOBE_FILL_SIGN,fillsignUiName:o.ADOBE_FILL_SIGN,illustratorMimeType:s.ADOBE_ILLUSTRATOR,illustratorUiName:o.ADOBE_ILLUSTRATOR,indesignMimeType:s.ADOBE_INDESIGN,indesignUiName:o.ADOBE_INDESIGN,pdfMimeType:s.ADOBE_PDF,pdfUiName:o.ADOBE_PDF,photoshopMimeType:s.ADOBE_PHOTOSHOP,photoshopUiName:o.ADOBE_PHOTOSHOP,htmlMimeType:s.HTML,htmlUiName:o.HTML,imageMimeType:s.IMAGE,imageUiName:n.IMAGE,excelMimeType:s.MS_EXCEL,excelUiName:o.MS_EXCEL_VIRGO,powerpointMimeType:s.MS_POWERPOINT,powerpointUiName:o.MS_POWERPOINT_VIRGO,wordMimeType:s.MS_WORD,wordUiName:o.MS_WORD_VIRGO,textMimeType:s.TEXT,textUiName:n.TEXT,videoMimeType:s.VIDEO,videoUiName:n.VIDEO,zipMimeType:s.ZIP,zipUiName:o.ZIP})),this}}),e.VirgoFilterFileTypeMenuView}),define("files/dev/views/virgo-filter-navigation-view",["core/ac-core","files/ac-files","files/templates/virgo-filter-navigation-template","i18n!core/nls/ui-strings","i18n!files/nls/ui-strings","core/utils/file-types","core/utils/css-util","core/utils/sc-analytics","core/views/menu-view","core/views/input-search-view","files/views/filter-added-by-menu-view","files/views/filter-attr-menu-view","files/views/virgo-filter-date-menu-view","files/views/virgo-filter-file-type-menu-view"],function(e,t,n,r,i,s,o,u){return t.VirgoFilterNavigationView=e.MenuView.extend({events:function(){return _.extend({},e.MenuView.prototype.events,{"click .type-button":"_onSelectAttrTypeMenuItem","click .time-button":"_onSelectAttrTimeMenuItem","click .filename-button":"_onSelectAttrFileNameMenuItem","click .files-filter-menu-value-menu-btn-label-reset":"_onResetButtonClick"})},initialize:function(){e.MenuView.prototype.initialize.call(this),this._addFocusEventListener(),this._addKeyEventListener(),this.listenTo(this.options.searchUiModel,"ConvertedFilesShowFilterEvent",_.bind(function(){this.$valueMenuBtnReset.css("display","block")},this))},render:function(){var t=this.$el,s=this.options;e.MenuView.prototype.render.call(this),t.children().length===0&&(t.html(_.template(n)({filterBy:i.FILTER_BY,selectAttribute:i.SELECT_ATTRIBUTE,selectValueAnyType:r.VIRGO_ANY_TYPE,selectValueAnyTime:r.VIRGO_ANY_TIME,selectValueAnyFileName:r.VIRGO_ANY_FILE_NAME,viewId:s.viewId})),this._initWrappers()),this.$attrMenuBtnLabelType.text(r.VIRGO_ANY_TYPE),this.$attrMenuBtnLabelTime.text(r.VIRGO_ANY_TIME),this.$attrMenuBtnLabelName.text(r.VIRGO_ANY_FILE_NAME),setInterval(_.bind(function(){this._handleResize()},this),250),this.$attrMenuBtnName.attr("title",""),this.$attrMenuBtnType.attr("title",""),this.$attrMenuBtnTime.attr("title",""),this.$valueMenuBtnLabelType.text(r.VIRGO_ANY_TYPE),this.$valueMenuBtnLabelTime.text(r.VIRGO_ANY_TIME),this.$valueMenuBtnLabelName.text(r.VIRGO_ANY_FILE_NAME),this.$valueMenuBtnLabelReset.text(r.VIRGO_RESET_FILTER),this.$valueMenuBtnReset.attr("title",r.VIRGO_RESET_FILTER),this.$valueMenuBtnLabelType.attr("aria-label",r.VIRGO_ANY_TYPE),this.$valueMenuBtnLabelTime.attr("aria-label",r.VIRGO_ANY_TIME),this.$valueMenuBtnLabelName.attr("aria-label",r.VIRGO_ANY_FILE_NAME),this.$valueMenuBtnLabelReset.attr("aria-label",r.VIRGO_RESET_FILTER);var o=this.options.appApi.connectorsApi.getConnectorPluginName(s.pluginId);return o==="root"&&this.options.searchUiModel.get("field_queries").models[0]&&this.options.searchUiModel.get("field_queries").models[0].get("field")==e.SearchUiModel.FIELD_FILE_ADDED_BY&&this.options.searchUiModel.get("field_queries").models[0].get("value")==e.SearchUiModel.CLIENT_ID_CPDF?this.$valueMenuBtnReset.css("display","block"):this.$valueMenuBtnReset.css("display","none"),this._filterValue===""||this._filterValue===undefined?(this._triggerViewEvent(e.ViewEvents.REMOVE_NAME_FIELD_QUERY),this.$(".filename-label-button").text(r.VIRGO_ANY_FILE_NAME),this.$(".filename-label-button").attr("title",r.VIRGO_ANY_FILE_NAME),this.$(".filename-label-button").attr("aria-label",r.VIRGO_ANY_FILE_NAME)):(this.$valueMenuBtnReset.css("display","block"),this.$(".filename-label-button").text(this._filterValue),this.$(".filename-label-button").attr("title",this._filterValue),this.$(".filename-label-button").attr("aria-label",this._filterValue)),this._filterValueType===""||this._filterValueType===undefined?(this._triggerViewEvent(e.ViewEvents.REMOVE_TYPE_FIELD_QUERY),this.$valueMenuBtnLabelType.text(r.VIRGO_ANY_TYPE),this.$valueMenuBtnLabelType.attr("aria-label",r.VIRGO_ANY_TYPE),this.$valueMenuBtnLabelType.attr("title",r.VIRGO_ANY_TYPE)):(this.$valueMenuBtnReset.css("display","block"),this.$valueMenuBtnLabelType.text(this._filterValueType),this.$valueMenuBtnLabelType.attr("aria-label",this._filterValueType),this.$valueMenuBtnLabelType.attr("title",this._filterValueType)),this._filterValueTime===""||this._filterValueTime===undefined?(this._triggerViewEvent(e.ViewEvents.REMOVE_TIME_FIELD_QUERY),this.$valueMenuBtnLabelTime.text(r.VIRGO_ANY_TIME),this.$valueMenuBtnLabelTime.attr("aria-label",r.VIRGO_ANY_TIME),this.$valueMenuBtnLabelTime.attr("title",r.VIRGO_ANY_TIME)):(this.$valueMenuBtnReset.css("display","block"),this.$valueMenuBtnLabelTime.text(this._filterValueTime),this.$valueMenuBtnLabelTime.attr("aria-label",this._filterValueTime),this.$valueMenuBtnLabelTime.attr("title",this._filterValueTime)),this.$attrMenuBtnType.removeClass("selected").removeAttr("aria-expanded"),this.$attrMenuBtnTime.removeClass("selected").removeAttr("aria-expanded"),this.$attrMenuBtnName.removeClass("selected").removeAttr("aria-expanded"),this.$valueMenuBtnName.removeClass("selected").removeAttr("aria-expanded"),this.$valueMenuBtnLabelTime.removeClass("selected").removeAttr("aria-expanded"),this.$valueMenuBtnLabelType.removeClass("selected").removeAttr("aria-expanded"),this.$valueMenuBtn.removeClass("selected").removeAttr("aria-expanded"),s.searchUiModel.get("is_locked")&&this.$filterSubmenuBtns.addClass("disabled"),this.$valueField.css("display","none"),this._renderChildViews(),this},open:function(t){return this.options.noUrlUpdate?this._logSiteCatalystEvent([u.FILTER,u.SHOWN]):this._logSiteCatalystEvent(u.SHOWN),e.MenuView.prototype.open.call(this,_.bind(function(){this._sizeInputField(),this._renderChildViews(),this._openMenuView(this.$attrMenuBtn,this._attrMenuView,t,!0)},this))},close:function(t){var n=this.$valueField;e.MenuView.prototype.close.call(this,t),n.val()&&this._fileNameContainsView.commitText()},_onBodyClick:function(t){$(t.target).hasClass("clear-btn")&&this.$valueField.val(""),e.MenuView.prototype._onBodyClick.call(this,t)},_initWrappers:function(){e.MenuView.prototype._initWrappers.call(this),this.$attrMenuBtn=this.$(".files-filter-menu-attr-menu-btn"),this.$attrMenuBtnType=this.$(".files-filter-menu-attr-menu-btn-type"),this.$attrMenuBtnTime=this.$(".files-filter-menu-attr-menu-btn-time"),this.$attrMenuBtnName=this.$(".files-filter-menu-attr-menu-btn-name"),this.$attrMenuBtnLabel=this.$(".files-filter-menu-attr-menu-btn-label"),this.$attrMenuBtnLabelType=this.$(".files-filter-menu-attr-menu-btn-label-type"),this.$attrMenuBtnLabelTime=this.$(".files-filter-menu-attr-menu-btn-label-time"),this.$attrMenuBtnLabelName=this.$(".files-filter-menu-attr-menu-btn-label-name"),this.$valueMenuBtn=this.$(".files-filter-menu-value-menu-btn"),this.$valueMenuBtnType=this.$(".files-filter-menu-value-menu-btn-type"),this.$valueMenuBtnTime=this.$(".files-filter-menu-value-menu-btn-time"),this.$valueMenuBtnName=this.$(".files-filter-menu-value-menu-btn-name"),this.$valueMenuBtnLabel=this.$(".files-filter-menu-value-menu-btn-label"),this.$valueMenuBtnLabelType=this.$(".files-filter-menu-value-menu-btn-label-type"),this.$valueMenuBtnLabelTime=this.$(".files-filter-menu-value-menu-btn-label-time"),this.$valueMenuBtnLabelName=this.$(".files-filter-menu-value-menu-btn-label-name"),this.$valueMenuBtnLabelReset=this.$(".files-filter-menu-value-menu-btn-label-reset"),this.$valueField=this.$(".files-filter-menu-value-field"),this.$attrMenu=this.$(".files-filter-menu-attr-menu"),this.$fileAddedByAttr=this.$(".files-filter-menu-attr-menu-item.file-added-by"),this.$fileTypeMenu=this.$(".files-filter-menu-file-type-menu"),this.$fileAddedByMenu=this.$(".files-filter-menu-file-added-by-menu"),this.$dateMenu=this.$(".files-filter-menu-date-menu"),this.$virgoFilterBtn=this.$(".virgo-filter-btn"),this.$virgoFilterValueBtn=this.$(".virgo-filter-value-btn"),this.$filterSubmenuBtns=this.$(".files-filter-menu-submenu-btn"),this.$valueMenuBtnReset=this.$(".reset-button")},_sizeInputField:function(){var e=this.$valueField,t=this.$attrMenuBtnName;e.width(o.getFullWidth(t)-o.getExtraWidth(e)-300),e.height(t.height())},_renderChildViews:function(){return this.removeAllChildViews(),this._renderChildView("_fileNameContainsView",e.InputSearchView,this.$valueField,{searchField:e.SearchUiModel.FIELD_FILE_NAME}),this._renderChildView("_fileTypeMenuView",t.VirgoFilterFileTypeMenuView,this.$fileTypeMenu,{$menuBtn:this.$valueMenuBtnType,triggerEl:this.$valueMenuBtnType.get(0)}),this._renderChildView("_dateMenuView",t.VirgoFilterDateMenuView,this.$dateMenu,{$menuBtn:this.$valueMenuBtnTime,triggerEl:this.$valueMenuBtnTime.get(0)}),this},_getMenuButtonDownArrow:function(e){return e.find(".files-filter-menu-btn-down-arrow")},_openMenuView:function(e,t,n,r){this.options.searchUiModel.get("is_locked")||(e.addClass("selected").attr("aria-expanded","true"),t.open(n,r))},_toggleMenuView:function(e,t){if(this.options.searchUiModel.get("is_locked")||!t){e.removeClass("selected").removeAttr("aria-expanded");return}var n=t.isMenuOpen();e.toggleClass("selected",!n),n?(e.removeClass("selected").removeAttr("aria-expanded"),t.close()):(e.addClass("selected").attr("aria-expanded","true"),t.open().always(function(){e.removeClass("selected").removeAttr("aria-expanded")}))},_getSiteCatalystContext:function(){return this.options.noUrlUpdate?undefined:[u.SEARCH_BAR,u.FILTER]},_getLogFilterName:function(e){var t="";switch(e){case"Type":t=u.VIRGO_FILTER_TYPE;break;case"Time":t=u.VIRGO_FILTER_TIME;break;case"Name":t=u.VIRGO_FILTER_FILENAME}return t},_onViewEvent:function(n,i){var s,o,a,f,l=e.SearchUiModel;n===t.ViewEvents.SELECT_FILTER_MENU_ITEM?(s={value:i.filterMenuItemValue,filter:i.filterMenuItemFilter,siteCatalyst:i.filterMenuItemSiteCatalyst,queryLabel:i.filterMenuItemQueryLabel,queryTitle:i.filterMenuItemQueryTitle},i.filterMenuType!=="attribute"&&this._onSelectValueMenuItem(s)):n===e.ViewEvents.ADD_SEARCH_FIELD_QUERY&&(a=this.$attrMenuBtn.data("data"),o=i.searchFieldQuery,o.commitQueryBox&&(this._triggerViewEvent(e.ViewEvents.REMOVE_NAME_FIELD_QUERY),this.close(),f=[],a===l.FIELD_FILE_NAME&&f.push(u.NAME),f.push(u.ENTERED),this._logSiteCatalystEvent(f),this.options.appApi.siteCatalystApi.logVirgoFiterEvent(this.options.pluginId,this._getLogFilterName(this._currFilterView)),this.$virgoFilterValueBtn.css("display","none"),o.value===""?(this.$(".filename-label-button").text(r.VIRGO_ANY_FILE_NAME),this.$(".filename-label-button").attr("title",r.VIRGO_ANY_FILE_NAME),this.$(".filename-label-button").attr("aria-label",r.VIRGO_ANY_FILE_NAME)):(this.$valueMenuBtnReset.css("display","block"),this.$(".filename-label-button").text(o.value),this.$(".filename-label-button").attr("title",o.value),this.$(".filename-label-button").attr("aria-label",o.value)),this._filterValue=o.value,this._currFilterView="",o.queryLabel=i.searchUiModel.getFieldQueryLabel(o),this.trigger(n,i)))},_onSelectAttrMenuItem:function(t){var n=this.$attrMenuBtn,r=this.$attrMenuBtnLabel,s=this.$valueMenuBtn,o=this.$valueMenuBtnLabel,u=this.$valueField,a=t.value,f=e.SearchUiModel,l;n.data("data",a),r.text(t.queryLabel),s.show(),u.hide(),delete this._valueMenuView;switch(a){case f.FIELD_FILE_NAME:s.hide(),u.show();case f.FIELD_FILE_TYPE:this._openMenuView(s,this._fileTypeMenuView),this._valueMenuView=this._fileTypeMenuView,this.$valueMenuBtnLabelType.text(i.SELECT_FORMAT),this.$valueMenuBtnLabelType.attr("aria-label",i.SELECT_FORMAT);break;case f.FIELD_FILE_ADDED_BY:this._openMenuView(s,this._addedByMenuView),this._valueMenuView=this._addedByMenuView,this.$valueMenuBtnLabel.text(i.SELECT_TOOL);break;case f.FIELD_DATE_ADDED:case f.FIELD_DATE_MODIFIED:case f.FIELD_DATE_LAST_ACCESS:this._openMenuView(s,this._dateMenuView),this._valueMenuView=this._dateMenuView,this.$valueMenuBtnLabelDate.text(i.SELECT_DATES)}this._logSiteCatalystEvent(t.siteCatalyst)},_onSelectAttrTypeMenuItem:function(){var t=this.$attrMenuBtnType,n=this.$attrMenuBtnLabelType,i=this.$valueMenuBtnType,o=this.$valueMenuBtnLabelType,u=this.$valueField,a=e.SearchUiModel,f;t.focus(),t.data("data",a.FIELD_FILE_TYPE),this.$valueMenuBtnTime.removeClass("selected").removeAttr("aria-expanded"),i.show(),u.hide(),delete this._valueMenuView;if(this._currFilterView!=="Type"||!this._fileTypeMenuView.isMenuOpen()){this._dateMenuView&&this._dateMenuView.close(),this._openMenuView(i,this._fileTypeMenuView),this._valueMenuView=this._fileTypeMenuView,this._currFilterView="Type";var l=s.UiName,c="";o.text()===r.VIRGO_ANY_TYPE?c="#sel11":o.text()===l.ADOBE_PDF?c="#sel12":o.text()===r.IMAGE?c="#sel13":o.text()===l.HTML?c="#sel14":o.text()===l.MS_WORD_VIRGO?c="#sel15":o.text()===l.MS_EXCEL_VIRGO?c="#sel16":o.text()===l.MS_POWERPOINT_VIRGO?c="#sel17":o.text()===r.TEXT?c="#sel18":o.text()===r.VIDEO?c="#sel19":o.text()===l.ZIP&&(c="#sel10"),this.$(c).css("display","block"),this.$(c).parent().addClass("selected")}else this._currFilterView=""},_onSelectAttrTimeMenuItem:function(){var t=this.$attrMenuBtnTime,n=this.$attrMenuBtnLabelTime,i=this.$valueMenuBtnTime,s=this.$valueMenuBtnLabelTime,o=this.$valueField,u=e.SearchUiModel,a;t.focus(),t.data("data",u.FIELD_DATE_ADDED),this.$valueMenuBtnType.removeClass("selected").removeAttr("aria-expanded"),i.show(),o.hide(),delete this._valueMenuView;if(this._currFilterView!=="Time"||!this._dateMenuView.isMenuOpen()){this._fileTypeMenuView&&this._fileTypeMenuView.close(),this._openMenuView(i,this._dateMenuView),this._valueMenuView=this._dateMenuView;var f="";s.text()===r.VIRGO_ANY_TIME?f="#sel0":s.text()===r.VIRGO_VIRGO_PAST_HOUR?f="#sel1":s.text()===r.VIRGO_PAST_WEEK?f="#sel2":s.text()===r.VIRGO_PAST_MONTH?f="#sel3":s.text()===r.VIRGO_PAST_YEAR?f="#sel4":s.text()===r.CUSTOM&&(f="#sel5"),this.$(f).css("display","block"),this.$(f).parent().addClass("selected"),this._currFilterView="Time"}else this._currFilterView=""},_onSelectAttrFileNameMenuItem:function(){var t=this.$attrMenuBtnName,n=this.$attrMenuBtnLabelName,r=this.$valueMenuBtnName,i=this.$valueMenuBtnLabelName,s=this.$valueField,o=e.SearchUiModel,u;t.focus(),t.data("data",o.FIELD_FILE_NAME),this.$valueField.css("display","block"),this.$valueMenuBtnTime.removeClass("selected").removeAttr("aria-expanded"),this.$valueMenuBtnType.removeClass("selected").removeAttr("aria-expanded"),s.hide(),delete this._valueMenuView,this.$valueMenuBtnName.removeClass("selected").removeAttr("aria-expanded"),this._currFilterView!=="Name"?(this._fileTypeMenuView&&this._fileTypeMenuView.close(),this._dateMenuView&&this._dateMenuView.close(),this._currFilterView="Name",this.$valueMenuBtnType.removeClass("selected").removeAttr("aria-expanded"),this.$valueMenuBtnTime.removeClass("selected").removeAttr("aria-expanded"),this.$valueMenuBtnName.addClass("selected").attr("aria-expanded"),r.hide(),s.show(),s.attr("placeholder",this._filterValue),s.attr("text",this._filterValue),s.attr("value",this._filterValue),s.val(this._filterValue),s.focus()):this._currFilterView=""},_onSelectValueMenuItem:function(t){var n=this.$attrMenuBtn,i,s,o,a,f=e.SearchUiModel,l;s=t.queryTitle!=undefined&&t.queryTitle!=""?t.queryTitle:t.queryLabel,o=n.data("data"),a=[];if(this._currFilterView==="Type")l=u.FILE_TYPE,o=f.FIELD_FILE_TYPE,this._filterValueType=t.queryLabel,this.$valueMenuBtnLabelType.text(t.queryLabel),this.$valueMenuBtnLabelType.attr("title",s),this.$valueMenuBtnLabelType.attr("aria-label",s);else if(this._currFilterView==="Time"){var c=this.options.sortUiModel.get("mru_date_order"),h=this._filterValueTime==null||this._filterValueTime==""?r.VIRGO_ANY_TIME:this._filterValueTime;this.$valueMenuBtnLabelTime.attr("prevfilter",h),this._filterValueTime=t.queryLabel,this.$valueMenuBtnLabelTime.text(t.queryLabel),this.$valueMenuBtnLabelTime.attr("title",s),this.$valueMenuBtnLabelTime.attr("aria-label",s);var c=this.options.sortUiModel.get("mru_date_order"),p=e.SortUiModel;switch(c){case p.ORDER_BY_DATE_ADDED:l=u.DATE_ADDED,o=f.FIELD_DATE_ADDED;break;case p.ORDER_BY_DATE_MODIFIED:l=u.DATE_MODIFIED,o=f.FIELD_DATE_MODIFIED;break;case p.ORDER_BY_DATE_LAST_ACCESS:l=u.DATE_LAST_ACCESS,o=f.FIELD_DATE_LAST_ACCESS}}else this._currFilterView==="Name"&&(l=u.NAME,o=f.FIELD_FILE_NAME,this.$valueMenuBtnLabelName.text(t.queryLabel),this.$valueMenuBtnLabelName.attr("aria-label",t.queryLabel));a.push(l),a.push(t.siteCatalyst),this._logSiteCatalystEvent(a),this.options.appApi.siteCatalystApi.logVirgoFiterEvent(this.options.pluginId,this._getLogFilterName(this._currFilterView),t.siteCatalyst);var d=n.data("data-data");if(t.value=="custom"){var v=this.options,m=0;this._triggerViewEvent(e.ViewEvents.SHOW_CUSTOM_RANGE_DIALOG,{parentView:this.options.parentView,scContext:this._getParentScContext(),searchFieldQuery:{field:o,value:t.value,filter:t.filter,commitQueryBox:!0,queryLabel:i}}),this._currFilterView==="Time"&&(this._currFilterView=""),this.$valueMenuBtnReset.css("display","block")}else{var g="";this._currFilterView==="Type"?(this._triggerViewEvent(e.ViewEvents.REMOVE_TYPE_FIELD_QUERY),g=this.$attrMenuBtnType.text(),this.$valueMenuBtnType.removeClass("selected").removeAttr("aria-expanded"),this.$valueMenuBtnType&&this.$valueMenuBtnType.blur()):this._currFilterView==="Time"?(this._triggerViewEvent(e.ViewEvents.REMOVE_TIME_FIELD_QUERY),g=this.$attrMenuBtnTime.text(),this.$valueMenuBtnTime.removeClass("selected").removeAttr("aria-expanded"),this.$valueMenuBtnTime&&this.$valueMenuBtnTime.blur()):this._currFilterView==="Name"&&(this._triggerViewEvent(e.ViewEvents.REMOVE_NAME_FIELD_QUERY),g=this.$attrMenuBtnName.text(),this.$valueMenuBtnName&&(this.$valueMenuBtnName.removeClass("selected").removeAttr("aria-expanded"),this.$valueMenuBtnName.blur())),this._currFilterView="",i=_.template(r.FILTER_DISPLAY_VALUE,{field:$.trim(g),value:t.queryLabel}),this.$valueMenuBtnReset.css("display","block"),t.queryLabel!==r.VIRGO_ANY_TIME&&t.queryLabel!==r.VIRGO_ANY_TYPE&&t.queryLabel!==r.VIRGO_ANY_FILE_NAME&&this._triggerViewEvent(e.ViewEvents.ADD_SEARCH_FIELD_QUERY,{searchFieldQuery:{field:o,value:t.value,filter:t.filter,commitQueryBox:!0,queryLabel:i}})}this.$valueMenuBtnLabelType.text()===r.VIRGO_ANY_TYPE&&this.$valueMenuBtnLabelTime.text()===r.VIRGO_ANY_TIME&&this.$(".filename-label-button").text()===r.VIRGO_ANY_FILE_NAME&&this.$valueMenuBtnReset.css("display","none"),this.$valueMenuBtnType.removeClass("selected"),this.$valueMenuBtnTime.removeClass("selected"),this.$valueMenuBtnName.removeClass("selected"),this._valueMenuView!=="undefined"&&this._valueMenuView&&this._valueMenuView.close(),delete this._valueMenuView},_onResetButtonClick:function(){this._triggerViewEvent(e.ViewEvents.REMOVE_TYPE_FIELD_QUERY),this._triggerViewEvent(e.ViewEvents.REMOVE_TIME_FIELD_QUERY),this._triggerViewEvent(e.ViewEvents.REMOVE_NAME_FIELD_QUERY),this.$valueMenuBtnLabelType.text(r.VIRGO_ANY_TYPE),this.$valueMenuBtnLabelType.attr("title",r.VIRGO_ANY_TYPE),this.$valueMenuBtnLabelType.attr("aria-label",r.VIRGO_ANY_TYPE),this.$valueMenuBtnLabelTime.text(r.VIRGO_ANY_TIME),this.$valueMenuBtnLabelTime.attr("title",r.VIRGO_ANY_TIME),this.$valueMenuBtnLabelTime.attr("aria-label",r.VIRGO_ANY_TIME),this.$(".filename-label-button").text(r.VIRGO_ANY_FILE_NAME),this.$(".filename-label-button").attr("title",r.VIRGO_ANY_FILE_NAME),this.$(".filename-label-button").attr("aria-label",r.VIRGO_ANY_FILE_NAME),this.$valueField.hide(),this._currFilterView="",this._filterValue="",this._filterValueType="",this._filterValueTime="",this.$valueMenuBtnReset.css("display","none");var t=this.options.appApi.connectorsApi.getConnectorPluginName(this.options.pluginId);return t==="root"&&this.options.searchUiModel.get("field_queries").models[0]&&this.options.searchUiModel.get("field_queries").models[0].get("field")==e.SearchUiModel.FIELD_FILE_ADDED_BY&&this.options.searchUiModel.get("field_queries").models[0].get("value")==e.SearchUiModel.CLIENT_ID_CPDF&&(this._triggerViewEvent(e.ViewEvents.REMOVE_SEARCH_FIELD_QUERY,{searchFieldQuery:this.options.searchUiModel.get("field_queries").models[0]}),this.options.searchUiModel.trigger("ConvertedFilesHideFilterEvent")),!0},_isClickOutsideMenu:function(){return!1},_onAttrMenuBtnClick:function(){var e=this.$attrMenuBtn,t=this.$valueMenuBtn,n=_.bind(function(){t.removeData("data"),this._toggleMenuView(e,this._attrMenuView)},this);this._valueMenuView?this._valueMenuView.close(n):n()},_onKeyDown:function(e){var t=e.target,n=!1,r=e.which;$(".virgo-filter-btn").keyup(function(e){e.keyCode===13&&$("#id_of_button").click()}),r===13&&this.$virgoFilterBtn.is(t)&&console.log("enter"),this.$attrMenuBtn.is(t),this.$valueMenuBtn.is(t),r===13&&this.$valueMenuBtnReset.is(t)&&(n=this._onResetButtonClick(e));if(n)return n},_onMenuBtnKeyDown:function(e,t){var n=e.which,r=$(e.target);switch(n){case 32:case 38:case 40:this._consumeEvent(e);if(n===38&&t||n===40&&!t||n===32)return r.click(),!0}return!1},_onAttrMenuBtnKeyDown:function(e){return this._onMenuBtnKeyDown(e,this._attrMenuView.isMenuOpen())},_onValueMenuBtnKeyDown:function(e){return this._onMenuBtnKeyDown(e,this._valueMenuView.isMenuOpen())},_handleResize:function(){if(this._dateMenuView&&this._dateMenuView.isMenuOpen()){var e=this.$valueMenuBtnTime.position(),t=this.$valueMenuBtnTime.height()+o.getExtraHeight(this.$valueMenuBtnTime);this.$dateMenu.css("top",e.top+t+"px"),this.$dateMenu.css("left",e.left+"px"),this.$dateMenu.width(this.$valueMenuBtnTime.width()+o.getPaddingWidth(this.$valueMenuBtnTime))}if(this._fileTypeMenuView&&this._fileTypeMenuView.isMenuOpen()){var e=this.$valueMenuBtnType.position(),t=this.$valueMenuBtnType.height()+o.getExtraHeight(this.$valueMenuBtnType);this.$fileTypeMenu.css("top",e.top+t+"px"),this.$fileTypeMenu.css("left",e.left+"px"),this.$fileTypeMenu.width(this.$valueMenuBtnType.width()+o.getPaddingWidth(this.$valueMenuBtnType))}}}),t.VirgoFilterNavigationView}),define("files/dev/views/virgo-files-header-view",["core/ac-core","files/ac-files","files/templates/virgo-files-header-template","i18n!files/nls/ui-strings","core/utils/util","core/utils/view-util","core/utils/css-util","core/utils/sc-analytics","core/views/view","core/views/search-control-view","files/views/filter-menu-view","files/views/virgo-sort-menu-view","files/views/virgo-folder-navigation-view","files/views/virgo-filter-navigation-view"],function(e,t,n,r,i,s,o,u){return t.VirgoFilesHeaderView=e.View.extend({events:{"click .files-filter-menu-btn":"_onFilterMenuBtnClick","click .files-upload-btn":"_onUploadClick","mousedown .files-upload-btn":"_onUploadMouseDown","click .virgo-files-new-folder-btn":"_onNewFolderClick","click .files-sort-menu-btn":"_onSortMenuBtnClick","click .shared-header-btn-dc-listView":"_onShowListView","click .shared-header-btn-dc-thumbnailView":"_onShowThumbnailView","click .shared-header-btn-new-folder":"_onNewFolderBtnClick","click .shared-header-btn-filter":"_onFilterBtnClick"},initialize:function(){e.View.prototype.initialize.call(this),this._addFocusEventListener(),this._addKeyEventListener(),this._addUiModelEventListeners()},render:function(){var t=this.options,s=this.$el,u,a,f=t.appApi.pluginsApi,l=t.pluginId,c;e.View.prototype.render.call(this),s.children().length===0&&(c=f.getSelectorApi(l).getSelectorLabel(),s.html(_.template(n)({sort:r.SORT,uploadFile:r.UPLOAD_FILE,newFolder:r.NEW_FOLDER,filter:r.FILTER,listView:r.VIRGO_LIST_VIEW,thumbnailView:r.VIRGO_THUMBNAIL_VIEW,viewId:t.viewId,pluginSelectorId:f.getPluginSelectorId(l),documentCloudName:c})),this._initWrappers(),this._updateHeaderButtonsSelectionState(),u=this.$upload,(i.isIpad()||i.isIphone())&&(!e.Features.isFeatureEnabled("ios_upload_ui")||i.isIosVersion(5)||i.isIosVersion(4))&&u.hide(),t.noUpload&&u.hide(),t.enableDragAndDrop&&u.width(0),t.noNewFolder&&this.$newFolder.hide(),t.noRightBtns?this.$virgoBtnsRight.css("display","none"):this.$virgoBtnsRight.css("display","grid"),t.noSearchControl?this.$searchControl.hide():this.$searchControl.show(),t.noFilter&&this.$filterMenuBtn.hide(),t.noSort&&this.$sortMenuBtn.hide()),_.defer(_.bind(function(){a=this.$searchControl,a.width(Math.floor(s.width()-o.getFullWidth(this.$btnsRight))),this._renderChildViews(),this._positionFilterMenu(),s.height(o.getFullHeight(a))},this)),this._adjustLayout();var h=this.options.appApi.connectorsApi.getConnectorPluginName(t.pluginId);return h!=="root"&&h!=="ccloud"&&t.pluginId!=="scan_files"&&this.$virgoBtnsRight.css("display","none"),this},_initWrappers:function(){this.$searchControl=this.$(".search-control"),this.$btnsRight=this.$(".files-header-btns.right"),this.$virgoBtnsRight=this.$(".DC-header-listing-btns"),this.$filterMenuBtn=this.$(".files-filter-menu-btn"),this.$filterMenu=this.$(".files-filter-menu"),this.$newFolder=this.$(".virgo-files-new-folder-btn"),this.$upload=this.$(".files-upload-btn"),this.$uploadInput=this.$("input:file.file"),this.$sortMenuBtn=this.$(".files-sort-menu-btn"),this.$sortMenu=this.$(".files-sort-menu"),this.$documentCloudName=this.$(".document-cloud-name"),this.$listViewBtn=this.$(".shared-workflow-header-btn.listView"),this.$thumbnailViewBtn=this.$(".shared-workflow-header-btn.thumbnailView"),this.$filterBtn=this.$(".shared-workflow-header-btn.filter"),this.$newFolderBtn=this.$(".shared-workflow-header-btn.virgo-files-new-folder-btn"),this.$folderNavigation=this.$(".virgo-header-navigation"),this.$filterView=this.$(".shared-header-btn-filterView")},_adjustLayout:function(){var e=$(window).width();this.$el.hasClass("with-rhp")?(e<700?this.$virgoBtnsRight.css("display","none"):this.$virgoBtnsRight.css("display","grid"),this.$filterView.hasClass("shown")?this.$("#virgoNavigation").css("display",e>1100?"block":"none"):e<=1100&&this.$("#virgoNavigation").css("display","none"),this.$("#virgoNavigation").hasClass("shown")?this.$("#filterBtn").removeClass("disabled"):e<=1100?this.$("#filterBtn").addClass("disabled"):this.$("#filterBtn").removeClass("disabled")):(e<200?this.$virgoBtnsRight.css("display","none"):this.$virgoBtnsRight.css("display","grid"),this.$filterView.hasClass("shown")?this.$filterView.css("display",e>800?"block":"none"):e<=800&&this.$("#virgoNavigation").css("display","none"),this.$("#virgoNavigation").hasClass("shown")?this.$("#filterBtn").removeClass("disabled"):e<=800?this.$("#filterBtn").addClass("disabled"):this.$("#filterBtn").removeClass("disabled"))},_showHeaderBtnClickedEffect:function(e,t){s.showClickedEffect(e,"files-header-btn-active","files-header-btn-transition",t)},_renderChildViews:function(){var t=this._collectionUiModel;t||(t=this._collectionUiModel=e.uiModelFactory.create("CollectionUiModel")),this._renderFolderNavigationView(t),this._renderSearchControlView(),this._renderSortMenuView(),this.options.isInSearchResultsView&&this._updateSearchResultsView()},_updateSearchResultsView:function(){var e=this.options,t=e.pluginId,n=e.appApi.pluginsApi,i=n.getSelectorApi(t).getSelectorLabel(),s=e.searchModel.get("total_hits");if(!_.isUndefined(s)){var o=_.template(r.SEARCH_HEADER,{label:i,count:s});this.$documentCloudName.text(o),this.$documentCloudName.attr("title",o),this.$documentCloudName.attr("aria-label",_.template(e.searchUiModel.getHeaderAriaLabel(),{category:i,count:s}))}else this.$documentCloudName.text(i);this.$el.addClass("uss-search-active"),this.$folderNavigation.hide(),this.$virgoBtnsRight.hide(),this.$documentCloudName.show()},_updateFilterVisibility:function(){var e=this.$filterView,t=$("#folderItems"),n=$("#filesSearchResults"),r=this.options,i=this.options.appApi.connectorsApi.getConnectorPluginName(r.pluginId);i==="root"?(t=$("#dcFolderItems"),n=$("#dcFolderSearchItems"),e.hasClass("dc-shown")?(e.removeClass("dc-shown"),e.removeClass("shown"),t.removeClass("with-virgo-dc-folder-navigation"),n.removeClass("with-virgo-dc-folder-navigation"),this.$("#virgoNavigation").css("display","none"),this.$filterBtn.removeClass("button-selected")):(e.addClass("dc-shown"),e.addClass("shown"),t.hasClass("with-virgo-dc-folder-navigation")||t.addClass("with-virgo-dc-folder-navigation"),n.hasClass("with-virgo-dc-folder-navigation")||n.addClass("with-virgo-dc-folder-navigation"),this.$("#virgoNavigation").css("display","block"),this.$filterBtn.addClass("button-selected"))):i==="ccloud"?(t=$("#ccFolderItems"),n=$("#ccFolderSearchItems"),e.hasClass("cc-shown")?(e.removeClass("cc-shown"),e.removeClass("shown"),t.removeClass("with-virgo-cc-folder-navigation"),n.removeClass("with-virgo-cc-folder-navigation"),this.$("#virgoNavigation").css("display","none"),this.$filterBtn.removeClass("button-selected")):(e.addClass("cc-shown"),e.addClass("shown"),t.hasClass("with-virgo-cc-folder-navigation")||t.addClass("with-virgo-cc-folder-navigation"),n.hasClass("with-virgo-cc-folder-navigation")||n.addClass("with-virgo-cc-folder-navigation"),this.$("#virgoNavigation").css("display","block"),this.$filterBtn.addClass("button-selected"))):r.pluginId==="scan_files"&&(t=$("#scanFolderItems"),n=$("#scanFolderSearchItems"),e.hasClass("sc-shown")?(e.removeClass("sc-shown"),e.removeClass("shown"),t.removeClass("with-virgo-scan-folder-navigation"),n.removeClass("with-virgo-scan-folder-navigation"),this.$("#virgoNavigation").css("display","none"),this.$filterBtn.removeClass("button-selected")):(e.addClass("sc-shown"),e.addClass("shown"),t.hasClass("with-virgo-scan-folder-navigation")||t.addClass("with-virgo-scan-folder-navigation"),n.hasClass("with-virgo-scan-folder-navigation")||n.addClass("with-virgo-scan-folder-navigation"),this.$("#virgoNavigation").css("display","block"),this.$filterBtn.addClass("button-selected")));var s=$(window).width();this.$el.hasClass("with-rhp")?this.$filterView.hasClass("shown")?this.$filterView.css("display",s>1100?"block":"none"):s<=1100&&this.$("#virgoNavigation").css("display","none"):this.$filterView.hasClass("shown")?this.$filterView.css("display",s>800?"block":"none"):s<=800&&this.$("#virgoNavigation").css("display","none")},_renderFolderNavigationView:function(e){this._renderChildView("_virgoFolderNavigationView",t.VirgoFolderNavigationView,this.$folderNavigation,{collectionUiModel:e})},_renderSearchControlView:function(){this._renderChildView("_searchControlView",e.SearchControlView,this.$searchControl)},_renderFilterMenuView:function(){this._renderChildView("_filterMenuView",t.FilterMenuView,this.$filterMenu,{parentView:this})},_renderVirgoFilterMenuView:function(){this._renderChildView("_virgoFilterNavigationView",t.VirgoFilterNavigationView,this.$filterView,{parentView:this})},_renderSortMenuView:function(){this._renderChildView("_sortMenuView",t.VirgoSortMenuView,this.$sortMenu)},_positionFilterMenu:function(){var e=this.$filterMenuBtn,t=e.position();if(!t)return;this._filterMenuView.$el.css("right",this.$el.width()-t.left-o.getFullWidth(e)+1+"px")},_positionNavigationMenu:function(){var e=this.$folderNavigation,t=e.position();if(!t)return;this._virgoFolderNavigationView.$el.css("right",this.$el.width()-t.left-o.getFullWidth(e)+1+"px")},_updateUploadButtonFocusStyle:function(e){var t=this.$("input:file");!e&&t.is(document.activeElement)?t.addClass("focused"):t.removeClass("focused"),i.isIE8()&&s.detachAndReattachElement(t.next())},_onFocusIn:function(){this._updateUploadButtonFocusStyle()},_onFocusOut:function(){this._updateUploadButtonFocusStyle(!0)},_onKeyDown:function(e){var t=$(e.target),n=e.which,r=!1;if(!t.hasClass("shared-workflow-header-btn")||s.isElementHidden(this.$el))return r;var i;switch(n){case 32:case 13:if(!t.hasClass("disabled"))if(t.hasClass("listView"))this._onShowListView(),r=!0;else if(t.hasClass("thumbnailView"))this._onShowThumbnailView(),r=!0;else if(t.hasClass("filter")){this._onFilterBtnClick();var o=this.$filterView.find(":focusable");o&&o.length>0&&(i=o.first().attr("tabindex",0)),r=!0}else t.hasClass("virgo-files-new-folder-btn")&&(this._onNewFolderClick(e),r=!0)}return i&&i.length===1&&i.focus(),r},_onFilterMenuBtnClick:function(){this.options.noUrlUpdate?this._logSiteCatalystEvent([u.FILTER_ICON,u.CLICKED]):this._logSiteCatalystEvent([u.SEARCH_BAR,u.FILTER_ICON,u.CLICKED]),this._triggerViewEvent(t.ViewEvents.FILTER_MENU_BTN_CLICK)},_onMenuBtnKeyDown:function(e,t){var n=e.which,r=e.target;switch(n){case 32:case 38:case 40:this._consumeEvent(e);if(n===38&&t||n!==38&&!t)return r.click(),!0}return!1},_onFilterMenuBtnKeyDown:function(e){return this._onMenuBtnKeyDown(e,this._filterMenuView.isMenuOpen())},_onUploadMouseDown:function(e){i.isIE()&&!i.isIE9orBelow()&&($(e.target).click(),e.preventDefault())},_onUploadClick:function(){this._logSiteCatalystEvent([u.UPLOAD_ICON,u.CLICKED])},_onNewFolderClick:function(e){this.$newFolderBtn.addClass("button-selected");var n=this.options;$(e.currentTarget).hasClass("disabled")||(this._logSiteCatalystEvent([u.NEW_FOLDER_ICON,u.CLICKED]),this._triggerViewEvent(t.ViewEvents.NEW_FOLDER,{parentFolderId:n.appApi.folderApi.getCurrentFolderId(n.pluginId),parentView:this,scContext:this._getParentScContext()}))},_onSortMenuBtnClick:function(){this.options.noUrlUpdate?this._logSiteCatalystEvent([u.SORT_ICON,u.CLICKED]):this._logSiteCatalystEvent([u.SEARCH_BAR,u.SORT_ICON,u.CLICKED]),this._triggerViewEvent(t.ViewEvents.SORT_MENU_BTN_CLICK)},_onSortMenuBtnKeyDown:function(e){return this._onMenuBtnKeyDown(e,this._sortMenuView.isMenuOpen())},_onFilesHeaderBtnKeyDown:function(e){var t=this.options,n=$(e.target),r=e.which,o=e.shiftKey,u=this.$btnsRight,a,f=!1,l=this.$("input:file").is(n);switch(r){case 13:case 32:l?i.isIE()&&(t.fileUploadModel.hasAjaxFileUpload()?n.click():r===13&&i.isIE9orBelow()&&(f=!0)):(f=!0,n.click());break;case 9:l&&(a=s.getNextFocusableDescendant(u,o,!0),f=!0);break;case 37:case 38:a=s.getNextFocusableDescendant(u,!0,!0),f=!0;break;case 39:case 40:a=s.getNextFocusableDescendant(u,!1,!0),f=!0}return f&&this._consumeEvent(e),a&&a.focus(),f},_addUiModelEventListeners:function(){var e=this.options,t=e.searchUiModel,n=e.filesUiModel,r=e.appApi.pluginsApi.getPluginsUiModel(e.pluginId);this.listenTo(t,"change:status",this._onSearchStatusChange).listenTo(n,"change:show_filter_menu",this._onShowFilterMenuChange).listenTo(n,"change:show_sort_menu",this._onShowSortMenuChange).listenTo(t,"ConvertedFilesShowFilterEvent",_.bind(function(){this.$filterView.hasClass("dc-shown")||this._onFilterBtnClick()},this)).listenTo(t,"ConvertedFilesHideFilterEvent",_.bind(function(){this.$filterView.hasClass("dc-shown")&&this._onFilterBtnClick()},this)),e.isInSearchResultsView&&(this.listenTo(e.searchModel,"change:total_hits",this.render),this.listenTo(r,"change:selected_searched_plugin_id",this._searchPluginChanged))},_searchPluginChanged:function(e,t){t==="search_summary"?this.$el.show():this.$el.hide()},_onSearchStatusChange:function(){this.options.searchUiModel.isSearching()?(this.$newFolder.addClass("disabled").prop("disabled",!0),this.$upload.addClass("disabled"),this.$upload.find("input").prop("disabled",!0)):(this.$newFolder.removeClass("disabled").prop("disabled",!1),this.$upload.removeClass("disabled").prop("disabled",!1),this.$upload.find("input").prop("disabled",!1))},_onShowFilterMenuChange:function(e,t){var n=this._filterMenuView,r,i=this.$filterMenuBtn;t?(r=this.options.filesUiModel,n.open().always(function(){i.removeClass("selected").removeAttr("aria-expanded"),r.set("show_filter_menu",!1,{silent:!0})}),i.addClass("selected").attr("aria-expanded","true")):n.close()},_onShowSortMenuChange:function(e,t){var n=this._sortMenuView,r,i=this.$sortMenuBtn;if(this.options.isInSearchResultsView)return;t?(r=this.options.filesUiModel,n.open().always(function(){i.removeClass("selected").removeAttr("aria-expanded"),r.set("show_sort_menu",!1,{silent:!0})}),i.addClass("selected").attr("aria-expanded","true")):n.close()},_onShowListView:function(){this.$thumbnailViewBtn.removeClass("button-selected"),this.$listViewBtn.addClass("button-selected"),this.options.collectionsUiModel.set("view","list");var t="list";this._logSiteCatalystEvent([u.VIEW_BY,t==="list"?u.LIST:u.THUMB,u.CHECKED]),this._triggerViewEvent(e.ViewEvents.VIEW_BY,{view:t})},_onShowThumbnailView:function(){this.$thumbnailViewBtn.addClass("button-selected"),this.$listViewBtn.removeClass("button-selected"),this.options.collectionsUiModel.set("view","thumbnail");var t="thumbnail";this._logSiteCatalystEvent([u.VIEW_BY,t==="list"?u.LIST:u.THUMB,u.CHECKED]),this._triggerViewEvent(e.ViewEvents.VIEW_BY,{view:t})},_updateHeaderButtonsSelectionState:function(){var e=this.options.collectionsUiModel.get("view");e==="list"?(this.$thumbnailViewBtn.removeClass("button-selected"),this.$listViewBtn.addClass("button-selected")):e==="thumbnail"&&(this.$thumbnailViewBtn.addClass("button-selected"),this.$listViewBtn.removeClass("button-selected"))},_onNewFolderBtnClick:function(){this.$newFolderBtn.addClass("button-selected"),this.options.appApi.siteCatalystApi.logVirgoCreateFolderEvent(this.options.appApi.siteCatalystApi._getLogSubCategory(this.options.pluginId))},_onFilterBtnClick:function(){this.$("#filterBtn").hasClass("disabled")||(this._updateFilterVisibility(),this._renderVirgoFilterMenuView())}}),t.VirgoFilesHeaderView}),define("files/dev/templates/files-rhp-template",[],function(){return'
'}),define("files/dev/views/files-rhp-view",["core/ac-core","files/ac-files","files/templates/files-rhp-template","core/utils/view-util","i18n!core/nls/ui-strings","core/views/rhp-preview-view","core/views/rhp-properties-view","core/views/rhp-actions-view","core/views/view"],function(e,t,n,r,i){return t.FilesRhpView=e.View.extend({initialize:function(){e.View.prototype.initialize.call(this)},render:function(){var t;return e.View.prototype.render.call(this),t=this.$el,t.children().length===0&&(t.html(_.template(n)),this._initWrappers()),this.options.isInSearchResultsView&&this._initWrappers(),this._addUiModelEventListeners(),this._addKeyEventListener(),this._renderChildViews(),this},_initWrappers:function(){this.$preview=this.$(".files-rhp-preview"),this.$properties=this.$(".files-rhp-properties"),this.$actions=this.$(".files-rhp-actions"),this.$totalFiles=this.$(".files-rhp-properties-total-files-value"),this.$totalFilesText=this.$(".files-rhp-properties-total-files-text-value"),this.$menuBreak=this.$(".files-rhp-menu-break")},_renderChildViews:function(){var t=this.options,n=t.selectionUiModel,r,s,o=n.getSingleSelectedItemModel(),u=t.pluginId==="root",a=o&&o.isRecentFileItem?u:!u;if(t.isInSearchResultsView&&o&&(o.workflowType||a)){this.$el.hide();return}this.$el.show(),r=n.getNumSelectedFiles(),s=n.getNumSelectedFolders(),r+s>1?(this.$totalFilesText.text(r+s+" "+i.ITEMS_SELECTED),this.$preview.hide(),this.$properties.hide(),this.$totalFiles.show(),this.$menuBreak.show()):(this.$totalFiles.hide(),this.$menuBreak.hide(),this.$preview.show(),this.$properties.show(),this._renderChildView("_previewView",e.RhpPreviewView,this.$preview),this._renderChildView("_propertiesView",e.RhpPropertiesView,this.$properties)),this._renderChildView("_actionsView",e.RhpActionsView,this.$actions)},_addUiModelEventListeners:function(){var e=this.options;this.listenTo(e.selectionUiModel,"change:selected_item_models",this._onSelectedItemModelsChange).listenTo(e.rhpPreviewUiModel,"change:actions_expanded",this._onActionsExpandedChange)},_onSelectedItemModelsChange:function(e){if(e.isSelectionMasked())return;e.getNumSelectedItems()>0&&this._renderChildViews()},_onKeyDown:function(e){var t=this.$el,n,i=e.which,s=e.shiftKey,o=!1;if(!r.descendantHasFocus(t))return o;switch(i){case 13:o=!0,$(e.target).click();break;case 9:n=r.getNextFocusableDescendant(t,s,!0)}return n&&n.length===1&&(o=!0,n.focus()),o}}),t.FilesRhpView}),define("files/dev/templates/file-save-as-header-template",[],function(){return'
'}),define("files/dev/templates/file-save-as-options-template",[],function(){return'
<%= reduceFileSize %>
<%= restrictEditing %>
<% if (typeof(title) !== "undefined") { %>
<%= title %>
<%= content %>
<% } %>'}),define("files/dev/views/file-save-as-options-view",["core/ac-core","files/ac-files","files/templates/file-save-as-options-template","i18n!files/nls/ui-strings","core/utils/view-util","core/views/view"],function(e,t,n,r,i){return t.FileSaveAsOptionsView=e.View.extend({events:{"click .restrict-editing":"_onRestrictEditingClicked","click .reduce-file-size":"_onReduceFileSizeClicked","click .close-img":"_onWalkthroughCloseClicked","click .reduce-file-size-walkthrough":"_onWalkthroughClicked"},initialize:function(){e.View.prototype.initialize.call(this),this._addKeyEventListener(),this._addFocusEventListener();var t=r.RESTRICT_EDITING;t=t||"Restrict Editing !!!";var i=r.REDUCE_FILE_SIZE;i=i||"Reduce File Size !!!";var s=this.options.appApi.saveAsApi;s.getFileOptionsRFS()!==undefined&&(i=s.getFileOptionsRFS());var o=s.getOriginalFileSize(),u=s.getShowReduceSizeBanner(),a={restrictEditing:t,reduceFileSize:i};if(u&&o!==0){var f=_.template(r.OPTIMIZE_CHECKBOX_COACKMARK_CONTENT,{fileSizeInMB:o});a.title=r.OPTIMIZE_CHECKBOX_COACKMARK_TITLE,a.content=f}this._template=_.template(n)(a)},render:function(){var t=this.$el;e.View.prototype.render.call(this);if(t.children().length===0){t.html(this._template),this._initWrappers(),this._disableOptionsIfNotAllowedOnDoc();var n=this.options.appApi.saveAsApi;n.isRestrictEditingVisible()||this.$(".restrict-editing").hide(),n.isReduceFileSizeVisible()||this.$(".reduce-file-size").hide(),n.isReduceFileSizeSelected()&&this.$walkthrough.hide()}return this.$(".reduce-file-size").attr("tabIndex","0"),this._refreshView(),this},_onFocusIn:function(e){var t=$(e.target);return this.$(":focusable").not(t).attr("tabIndex",-1),t.attr("tabindex",0),!0},_onFocusOut:function(e){},_onKeyDown:function(e){var t=this.$el,n=$(e.target),r,s=$.Event("click"),o=e.which,u=o===37,a=!1;if(!i.descendantHasFocus(t))return a;switch(o){case 13:case 32:n.trigger(s),a=!0;break;case 37:case 39:r=i.getNextFocusableDescendant(t,u,!0)}return r&&r.length===1&&(a=!0,r.focus()),a},_initWrappers:function(){this.$restrictEditing=this.$(".restrict-editing"),this.$reduceFileSize=this.$(".reduce-file-size"),this.$walkthrough=this.$(".reduce-file-size-walkthrough")},_onRestrictEditingClicked:function(){var e=this.$restrictEditing,t=this.options.appApi.saveAsApi;if(!t.isRestrictEditingEnabled())return;var n=e.hasClass("selected"),r=!n,i=this;this.options.readerContextModel.done(function(s){var o=s.get("rna");if(o.hasProperty("viewData")){var u=o.get("viewData"),a=u.get("fileSelectData");a.invoke("restrictEditingChanged",r).done(function(n){var r=n!==undefined&&n!==!1;t.setRestrictEditing(r),i._setSelection(r,e)}).fail(function(){i._setSelection(n,e)})}}).fail(function(){i._setSelection(n,e)})},_onWalkthroughCloseClicked:function(){this.$walkthrough.hide(),events.stopPropagation()},_onWalkthroughClicked:function(){this._onReduceFileSizeClicked()},_onReduceFileSizeClicked:function(){var e=this.$reduceFileSize,t=this.options.appApi.saveAsApi;if(!t.isReduceFileSizeEnabled())return;var n=e.hasClass("selected"),r=!n;t.setReduceFileSize(r),t.setReduceFileSizeSelectedByPref(!1),this.$walkthrough.is(":visible")&&this.$walkthrough.hide(),this._setSelection(r,e)},_refreshView:function(){var e=this.options.appApi.saveAsApi;this._setSelection(e.isRestrictEditingSelected(),this.$restrictEditing),this._setSelection(e.isReduceFileSizeSelected(),this.$reduceFileSize)},_setSelection:function(e,t){var n=t.find(".checkbox");e?(t.addClass("selected"),n.addClass("selected")):(t.removeClass("selected"),n.removeClass("selected"))},_disableOptionsIfNotAllowedOnDoc:function(){var e=this.options.appApi.saveAsApi,t=e.isRestrictEditingEnabled();t||this._disableEl(this.$restrictEditing);var n=e.isReduceFileSizeEnabled();n||this._disableEl(this.$reduceFileSize)},_disableEl:function(e){e.addClass("disabled"),e.find(".checkbox").addClass("disabled")},_formatFileSize:function(e){var t=[" bytes"," KB"," MB"," GB"," TB"],n=1024,r=e==0?0:Math.floor(Math.log(e)/Math.log(n));return(e/Math.pow(n,r)).toFixed(0)*1+t[r]}}),t.FileSaveAsOptionsView}),define("files/dev/views/file-save-as-header-view",["core/ac-core","files/ac-files","files/templates/file-save-as-header-template","i18n!core/nls/ui-strings","i18n!files/nls/ui-strings","core/utils/view-util","core/views/view","files/views/export-options-view","files/views/file-save-as-options-view"],function(e,t,n,r,i,s){var o=!1;return t.FileSaveAsHeaderView=e.View.extend({events:{"keydown .file-save-as-filename-input":"_onNewFileNameKeyDown","keyup .file-save-as-filename-input":"_onNewFileNameKeyUp","paste .file-save-as-filename-input":"_onNewFileNamePaste"},_onNewFileNameKeyDown:function(){this.options.selectionUiModel.clearSelection(),this._showIllegalNameError(!1)},_onNewFileNameKeyUp:function(){if(e.Util.isCEF()&&event.which===13)return;this._updateNewFileNameControls()},_onNewFileNamePaste:function(){this.options.selectionUiModel.clearSelection(),this._updateNewFileNameControls()},_updateNewFileNameControls:function(){var e=this._getNewFileName();this.options.appApi.saveAsApi.setFilename(e)},initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(n)({filenameText:i.FILENAME_TEXT}),this._addUiModelEventListeners()},render:function(){var t=this.options,n=this.$el,r=t.appApi.saveAsApi.getFilename();return e.View.prototype.render.call(this),n.children().length===0&&(n.html(this._template),this._initWrappers(),this.$filenameInput.val(r),this.$filenameInput.attr("aria-label",r),o||(_.delay(_.bind(function(){this.$filenameInput.focus(),this.$filenameInput.select()},this),1e3),o=!0)),this._getNewFileName()!==r&&(this.$filenameInput.val(r),this.$filenameInput.attr("aria-label",r)),this._renderChildViews(),this},_initWrappers:function(){this.$error=this.$(".file-save-as-error"),this.$errorCn=this.$(".file-save-as-error-container"),this.$filenameInput=this.$(".file-save-as-filename-input"),this.$saveAsOptions=this.$(".file-save-as-options")},_addUiModelEventListeners:function(){var e=this.options,t=e.selectionUiModel;this.listenTo(t,"change:selected_item_models",this._onSelectedItemModelsChange),e.appApi.saveAsApi.addSaveAsErrorCallback(this._onSaveAsError)},_onSelectedItemModelsChange:function(e){var t=this.options.appApi.saveAsApi;t.isRunningInFileSaveAs()&&(_.each(e.get("selected_item_models"),function(e){e.isFile()&&t.setFilename(e.get("name"))}),this.$filenameInput.val(t.getFilename()),this.$filenameInput.attr("aria-label",t.getFilename()))},_onSaveAsError:function(t,n){if(n&&n.error&&(n.error.code===e.ErrorUiModel.CODE_ILLEGAL_NAME||n.error.code===e.ErrorUiModel.CODE_INVALID_PARAMETER)){this._showIllegalNameError(!0),this.$filenameInput.focus().select();return}},_showIllegalNameError:function(e){var t=this.$error,n=this.$errorCn,i=this.options;e?(t.text(_.template(r.RENAME_ILLEGAL_NAME,{renamedType:r.FILE})),t.slideDown("fast",function(){n.slideDown("fast",function(){i.searchUiModel.trigger("change:search_control_height")})})):s.isElementHidden(t)||(t.slideUp("fast",function(){n.hide(),t.hide(),i.searchUiModel.trigger("change:search_control_height")}),i.appApi.saveAsApi.clearError())},_getNewFileName:function(){return $.trim(this.$filenameInput.val())},_renderChildViews:function(){this._renderOptionsView()},_renderOptionsView:function(){var e=this.options.appApi.saveAsApi;e.shouldShowExportOptions()?this._renderChildView("_exportOptionsView",t.ExportOptionsView,this.$saveAsOptions):e.shouldDisplaySaveAsOptions()?(this.$el.addClass("file-save-as-acrobat ui-theme theme-container"),this._renderChildView("_fileSaveAsOptionsView",t.FileSaveAsOptionsView,this.$saveAsOptions)):this.$saveAsOptions.hide()}}),t.FileSaveAsHeaderView}),define("files/dev/templates/files-footer-template",[],function(){return''}),define("files/dev/views/files-footer-view",["core/ac-core","files/ac-files","files/templates/files-footer-template","core/utils/view-util","core/views/view"],function(e,t,n,r){return t.FilesFooterView=e.View.extend({events:{"click .footer-link":"_onFooterLinkClick","keydown .footer-link":"_onKeyDown"},initialize:function(){e.View.prototype.initialize.call(this),this._addFocusEventListener(),this._template=_.template(n)},render:function(){return this.$el.children().length===0&&(this.$el.html(this._template({hyperLinkText:this.options.footerAnchorText})),this._initWrappers(),this._setTabbableItem()),this},_onFocusIn:function(e){var t=$(e.target);return this.$(":focusable").not(t).attr("tabindex",-1),t.attr("tabindex",0),!0},_onFocusOut:function(e){return!0},_setTabbableItem:function(){var e=this.$(".footer-link:focusable"),t=this.$(":tabbable");t.length===0&&e.attr("tabindex","0")},_onKeyDown:function(e){var t=this.$el,n=e.which,i=!1;if(!r.descendantHasFocus(t))return i;switch(n){case 13:i=!0,$(e.target).click();break;case 32:i=!0,$(e.target).click();break;case 9:i=!0}return i},_initWrappers:function(){this.$footerLink=this.$(".footer-link")},_onFooterLinkClick:function(){this._triggerViewEvent(e.ViewEvents.LAUNCH_FOOTER_URL_IN_BROWSER)}}),t.FilesFooterView}),define("files/dev/views/files-view",["core/ac-core","files/ac-files","files/templates/files-template","core/utils/css-util","core/utils/util","core/utils/view-util","core/views/view","files/views/virgo-files-header-view","files/views/files-header-view","files/views/files-body-view","files/views/files-rhp-view","files/views/full-preview-view","files/views/file-save-as-header-view","files/views/files-footer-view"],function(e,t,n,r,i,s){return t.FilesView=e.View.extend({initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(n),this._addUiModelEventListeners(),this._addAppApiCallbacks(),this._addKeyEventListener()},render:function(){var t=this.options,n=this.$el,s,o,u;e.View.prototype.render.call(this),n.children().length===0&&(n.html(this._template()),this._initWrappers()),this._renderChildViews();var t=this.options,a=t.pluginId,f=0;return this.options.appApi.selectionApi.isRunningInFileSelection()?s=this.$header:s=this.$virgoHeader,this.options.appApi.selectionApi.isRunningInFileSelection()||i.isCEF()&&this.options.appApi.saveAsApi.isRunningInFileSaveAs()||(f=16),o=this.$body,u=this.$saveAsHeader,_.defer(function(){var e=r.getFullHeight(u),n=0;i.isCEF()?(t.appApi.saveAsApi.isRunningInFileSaveAs()?(s.css("top","0px"),s.css("min-height","0px")):s.css("top",e),t.noFilesHeader||(n=r.getFullHeight(s)),o.css("top",e+n+f)):o.css("top",r.getFullHeight(s)+f)}),this},_initWrappers:function(){this.$header=this.$(".files-header"),this.$body=this.$(".files-body");if(this.options.isInSearchResultsView){this.$searchContextBoard=$(".search-context-board");var e=this.options.pluginId+"-rhpId",t=_.template('
');this.$searchContextBoard.append(t()),this.$rhp=this.$searchContextBoard.find("#"+e)}else this.$rhp=this.$(".files-rhp");this.$footer=this.$(".files-footer"),this.$saveAsHeader=this.$(".file-save-as-header"),this.$virgoHeader=this.$(".virgo-files-header"),this.$fullPreview=$(".full-preview")},_renderChildViews:function(){var e=this.options;this._renderFileSaveAsHeaderView(),this.options.appApi.selectionApi.isRunningInFileSelection()?this._renderFilesHeaderView():this._renderVirgoFilesHeaderView(),this._renderFilesBodyView(),this._renderRhpView(),this.options.appApi.pluginsApi.isInSearchResultsView()?this.$footer.hide():this._renderFilesFooterView(),!e.noFullPreview&&!e.noFullPreviewImpl&&this._renderFullPreviewView()},_renderFileSaveAsHeaderView:function(){var e=this.$saveAsHeader,n=this.options;i.isCEF()&&n.appApi.saveAsApi.isRunningInFileSaveAs()?(e.show(),this._renderChildView("_fileSaveAsHeaderView",t.FileSaveAsHeaderView,e)):e.hide()},_renderFilesHeaderView:function(){this.$virgoHeader.css("display","none"),this.options.appApi.selectionApi.isRunningInFileSelection()?this._renderChildView("_filesHeaderView",t.FilesHeaderView,this.$header):this.$header.hide(),this.options.noFilesHeader?this.$header.hide():this.$header.show()},_renderVirgoFilesHeaderView:function(){this.$header.css("display","none"),this.options.appApi.selectionApi.isRunningInFileSelection()?this.$virgoHeader.hide():this._renderChildView("_virgoFilesHeaderView",t.VirgoFilesHeaderView,this.$virgoHeader);if(this.options.noFilesHeader)this.$virgoHeader.hide();else{if(this.options.isInSearchResultsView){var e=this.options,n=e.appApi.pluginsApi.getPluginsUiModel(e.pluginId);if(n.get("selected_searched_plugin_id")===e.pluginId){this.$virgoHeader.hide();return}}this.$virgoHeader.show()}},_onKeyDown:function(e){var t=$(e.target),n=e.which,r=!1,i=e.shiftKey;if(s.isElementHidden(this.$el))return!1;if(i&&n===9)var o=this.$body.find(":focusable"),u=o.last().attr("tabindex",0);else if(n==117){var a=this.$rhp.hasClass("hidden")?!1:!0,f=t.closest(this.$rhp).length?!0:!1,u,l=this.$rhp.find(":focusable"),c=this.$body.find(".collection-item:tabbable"),h=this.$el.find(":tabbable"),p=e.altKey,d=e.ctrlKey;p||d&&(l.length==0||!a)?u=c.length>0?c:h.first().attr("tabindex",0):d?u=l.first().attr("tabindex",0):f?(i&&(u=c),l.attr("tabindex",-1)):a&&(i||l&&l.length>0&&(u=l.first().attr("tabindex",0))),u&&u.length>0&&(r=!0,u.focus());var v={};return v.isF6Consumed=r,v.shift=i,this.options.appApi.rnaApi.done(_.bind(function(e){e.rnaServicesAPI.f6KeyHandled(v)},this)),r}return r},_renderFilesBodyView:function(){this._renderChildView("_filesBodyView",t.FilesBodyView,this.$body)},_renderRhpView:function(){this._renderChildView("_rhpView",t.FilesRhpView,this.$rhp)},_renderFilesFooterView:function(){var e=this.options,n=this.$body,r=this.$footer,s=this.$rhp,o=e.appApi.pluginsApi,u=e.pluginId,a=$.Deferred();r.hide(),n.removeClass("with-footer"),s.removeClass("with-footer"),i.isCEF()&&e.footerAnchorText&&e.footerAnchorText.length>0&&u&&u.length>0&&(u==="root"||u==="ccloud"?a.resolve():o.callPluginMethod(u,"getFilesFooterUrl",undefined,this._getResolvedPromise(),!0).done(_.bind(function(e){e&&e.uri.length>0?a.resolve():a.reject()},this)),a.done(_.bind(function(){r.show(),n.addClass("with-footer"),s.addClass("with-footer"),this._renderChildView("_filesFooterView",t.FilesFooterView,r)},this)))},_renderFullPreviewView:function(){this._renderChildView("_fullPreviewView",t.FullPreviewView,this.$fullPreview)},_addUiModelEventListeners:function(){var e=this.options;this.listenTo(e.searchUiModel,"change:search_control_height",this._onSearchControlHeightChange).listenTo(e.collectionsUiModel,"change:view",this.updateChildViewSizes).listenTo(e.selectionUiModel,"change:selected_item_models",this._onSelectedItemModelsChange)},_onSearchControlHeightChange:function(){this.render()},_onSelectedItemModelsChange:function(e){var t=this.options,n=this.$header,i=this.$virgoHeader,s=this.$body,o=this.$rhp,u=t.appApi;if(t.noSelectionActions||u.acrobatApi.isInAcrobat())return;var a=$(window).width();if(e.isItemSelected()){if(!n.hasClass("with-rhp")||!i.hasClass("with-rhp"))i.addClass("with-rhp"),a<700?this.$("#headerRightBtns").css("display","none"):this.$("#headerRightBtns").css("display","grid"),this.$("#virgoNavigation").hasClass("shown")?this.$("#virgoNavigation").css("display",a>1100?"block":"none"):a<=1100&&this.$("#virgoNavigation").css("display","none"),this.$("#virgoNavigation").hasClass("shown")?this.$("#filterBtn").removeClass("disabled"):a<=1100?this.$("#filterBtn").addClass("disabled"):this.$("#filterBtn").removeClass("disabled"),this.options.appApi.siteCatalystApi.logVirgoRHPOpenedEvent(this.options.appApi.siteCatalystApi._getLogRHPSubCategory(this.options.pluginId)),n.addClass("with-rhp"),s.addClass("with-rhp"),this.$(".files-body div").addClass("with-rhp"),o.removeClass("hidden").removeClass("invisible")}else if(n.hasClass("with-rhp")||i.hasClass("with-rhp"))n.removeClass("with-rhp"),s.removeClass("with-rhp"),this.$(".files-body div").removeClass("with-rhp"),o.addClass("hidden"),i.removeClass("with-rhp"),a<200?this.$("#headerRightBtns").css("display","none"):this.$("#headerRightBtns").css("display","grid"),this.$("#virgoNavigation").hasClass("shown")?this.$("#virgoNavigation").css("display",a>800?"block":"none"):a<=800&&this.$("#virgoNavigation").css("display","none"),this.$("#virgoNavigation").hasClass("shown")?this.$("#filterBtn").removeClass("disabled"):a<=800?this.$("#filterBtn").addClass("disabled"):this.$("#filterBtn").removeClass("disabled");var f=this.options.appApi.connectorsApi.getConnectorPluginName(t.pluginId);(!!this.options.isInSearchResultsView||f!=="root"&&f!=="ccloud"&&t.pluginId!=="scan_files")&&this.$("#headerRightBtns").css("display","none"),r.addTransitionEndCallback(s,"right",_.bind(function(){n.removeClass("animating"),r.removeTransitionEndCallbacks(o),n.hasClass("with-rhp")||o.addClass("invisible"),this.render()},this))},_addAppApiCallbacks:function(){this.options.appApi.windowApi.addWindowResizeCallback(this.updateChildViewSizes)}}),t.FilesView}),define("files/dev/templates/files-offline-template",[],function(){return'
<%= workflowName %>
<%= title %>
<%= content %>
<%= ok_button %>
'}),define("files/dev/views/files-offline-view",["core/ac-core","files/ac-files","files/templates/files-offline-template","i18n!files/nls/ui-strings","core/views/view"],function(e,t,n,r){t.FilesOfflineView=e.View.extend({_offline_display_location:19,_offline_display_context:155,initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(n),this.$el.empty(),this.render()},events:function(){return _.extend({},e.View.prototype.events,{"click .ok-button":"_onOKButtonClick"})},render:function(){return e.View.prototype.render.call(this),this.$el.children().length===0&&(this.$el.html(this._template({workflowName:this.options.workflowName?this.options.workflowName:"",title:r.FILE_OFFLINE_TITLE,content:r.FILE_OFFLINE_CONTENT,ok_button:r.FILE_OFFLINE_OK_LABEL,ok_button_label:r.FILE_OFFLINE_ARIA_LABEL})),this._initWrappers()),this.options.workflowName==undefined&&this.$el.find(".shared-workflow-heading").hide(),this},_initWrappers:function(){this.$title=this.$(".title"),this.$content=this.$(".content"),this.$ok_button=this.$(".ok-button")},_onOKButtonClick:function(){this.options.appApi.networkConnectivityApi.resetNetworkStatus({silent:!1})},_getAriaLabel:function(){return this.offlineTitle+this.acceptLabel}})}),define("files/dev/templates/files-virgo-offline-template",[],function(){return'
<%= workflowName %>
<%= title %>
<%= content %>
<%= ok_button %>
'}),define("files/dev/views/files-virgo-offline-view",["core/ac-core","files/ac-files","files/templates/files-virgo-offline-template","i18n!files/nls/ui-strings","i18n!core/nls/ui-strings","core/views/view"],function(e,t,n,r,i){t.FilesVirgoOfflineView=e.View.extend({_offline_display_location:19,_offline_display_context:155,initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(n),this.$el.empty(),this.render()},events:function(){return _.extend({},e.View.prototype.events,{"click .ok-button":"_onOKButtonClick"})},render:function(){return e.View.prototype.render.call(this),this.$el.children().length===0&&(this.$el.html(this._template({workflowName:"",title:i.VIRGO_NO_INTERNET_CONNECTION_TITLE,content:i.VIRGO_NO_INTERNET_CONNECTION_DC_SUBTITLE,ok_button:r.FILE_OFFLINE_OK_LABEL,ok_button_label:r.FILE_OFFLINE_ARIA_LABEL})),this._initWrappers()),this.$content.text(this._getNoFilesText()),this.$(".dc-cc-workflow-name").text(this._getWorkflowName()),this},_getNoFilesText:function(){var e=this.options,t=this.options.appApi.connectorsApi.getConnectorPluginName(e.pluginId);return t==="root"?i.VIRGO_NO_INTERNET_CONNECTION_DC_SUBTITLE:t==="ccloud"?i.VIRGO_NO_INTERNET_CONNECTION_CC_SUBTITLE:i.VIRGO_NO_INTERNET_CONNECTION_OTHERS_SUBTITLE},_getWorkflowName:function(){if(this.options.pluginId==="scan_files")return r.VIRGO_SCANS;var e=this.options.appApi.connectorsApi.getConnectorPluginName(this.options.pluginId);return e==="root"?r.VIRGO_DOCUMENT_CLOUD:e==="ccloud"?r.VIRGO_CREATIVE_CLOUD:e==="desktop_sharepoint"?r.VIRGO_SHAREPOINT:e==="dropbox"?r.VIRGO_DROPBOX:e==="googleDrive"?r.VIRGO_GOOGLE_DRIVE:e==="box"?r.VIRGO_BOX:e==="onedrive"||e==="onedrivebusiness"?r.VIRGO_ONEDRIVE:i.HOME},_initWrappers:function(){this.$title=this.$(".title"),this.$content=this.$(".content"),this.$ok_button=this.$(".ok-button")},_onOKButtonClick:function(){this.options.appApi.networkConnectivityApi.resetNetworkStatusToOnline({silent:!1})},_getAriaLabel:function(){return this.offlineTitle+this.acceptLabel}})}),define("files/dev/templates/files-sign-out-template",[],function(){return'
<%= title %>
<%= content %>
'}),define("files/dev/views/files-sign-out-view",["core/ac-core","files/ac-files","files/templates/files-sign-out-template","i18n!files/nls/ui-strings","core/views/view"],function(e,t,n,r){return t.FilesSignOutView=e.View.extend({events:{"click .files-sign-in-btn":"_onSignInButtonClick"},initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(n)},render:function(){var t=this.$el;return e.View.prototype.render.call(this),t.children().length===0&&(t.html(this._template({title:this._getTitle(),content:this._getContent(),label:this._getButtonLabel()})),this._initWrappers()),this.options.noSignOutImage?this.$filesSignOutImage.hide():this._updateIcon(),this},_initWrappers:function(){this.$filesSignOutImage=this.$(".files-sign-out-image")},_updateIcon:function(){var e=this.options.appApi.connectorsApi.getConnectorSignOutImageClass(this.options.pluginId);e&&this.$filesSignOutImage.addClass(e)},_getTitle:function(){return this.options.filesSignOutTitle||this.options.appApi.connectorsApi.getConnectorSignOutTitle(this.options.pluginId)},_getContent:function(){return this.options.filesSignOutContent||this.options.appApi.connectorsApi.getConnectorSignOutContent(this.options.pluginId)},_getButtonLabel:function(){return this.options.filesSignInButtonLabel||r.FILES_SIGN_IN_LABEL},_onSignInButtonClick:function(){var e=this.options.appApi,t=this.$el;t.hide(),e.displayApi.showSpinner(!0),e.networkConnectivityApi.resetNetworkStatusToOnline({silent:!0}),e.sessionApi.ensureSignedIn().then(function(){e.displayApi.showSpinner(!1)},function(n){e.displayApi.showSpinner(!1),e.networkConnectivityApi.isOnline()&&(!n||n.errorString!=="NoAccessToPdfServices")&&t.show()})}}),t.FilesSignOutView}),define("files/dev/templates/files-virgo-sign-out-template",[],function(){return'
<%= workflowName %>
<%= title %>
<%= content %>
'}),define("files/dev/views/files-virgo-sign-out-view",["core/ac-core","files/ac-files","files/templates/files-virgo-sign-out-template","i18n!files/nls/ui-strings","i18n!core/nls/ui-strings","i18n!files/nls/ui-strings","core/views/view"],function(e,t,n,r,i,s){return t.FilesVirgoSignOutView=e.View.extend({events:{"click .files-sign-in-btn":"_onSignInButtonClick"},initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(n)},render:function(){var t=this.$el;return e.View.prototype.render.call(this),t.children().length===0&&(t.html(this._template({workflowName:"",title:i.VIRGO_NON_SIGNED_IN_DC_TITLE,content:i.VIRGO_NON_SIGNED_IN_DC_SUBTITLEE,label:i.VIRGO_NON_SIGNED_IN_ACTION})),this._initWrappers()),this.options.noSignOutImage?this.$filesSignOutImage.hide():this._updateIcon(),this.$(".dc-cc-workflow-name").text(this._getWorkflowName()),this},_initWrappers:function(){this.$filesSignOutImage=this.$(".files-sign-out-image")},_getWorkflowName:function(){if(this.options.pluginId==="scan_files")return s.VIRGO_SCANS;var e=this.options.appApi.connectorsApi.getConnectorPluginName(this.options.pluginId);return e==="root"?s.VIRGO_DOCUMENT_CLOUD:e==="ccloud"?s.VIRGO_CREATIVE_CLOUD:e==="desktop_sharepoint"?s.VIRGO_SHAREPOINT:e==="dropbox"?s.VIRGO_DROPBOX:e==="googleDrive"?s.VIRGO_GOOGLE_DRIVE:e==="box"?s.VIRGO_BOX:e==="onedrive"||e==="onedrivebusiness"?s.VIRGO_ONEDRIVE:i.HOME},_updateIcon:function(){var e=this.options.appApi.connectorsApi.getConnectorSignOutImageClass(this.options.pluginId);e&&this.$filesSignOutImage.addClass(e)},_getTitle:function(){return this.options.filesSignOutTitle||this.options.appApi.connectorsApi.getConnectorSignOutTitle(this.options.pluginId)},_getContent:function(){return this.options.filesSignOutContent||this.options.appApi.connectorsApi.getConnectorSignOutContent(this.options.pluginId)},_getButtonLabel:function(){return this.options.filesSignInButtonLabel||r.FILES_SIGN_IN_LABEL},_onSignInButtonClick:function(){var e=this.options.appApi,t=this.$el;t.hide(),e.displayApi.showSpinner(!0),e.networkConnectivityApi.resetNetworkStatusToOnline({silent:!0}),e.sessionApi.ensureSignedIn().then(function(){e.displayApi.showSpinner(!1)},function(n){e.displayApi.showSpinner(!1),e.networkConnectivityApi.isOnline()&&(!n||n.errorString!=="NoAccessToPdfServices")&&t.show()})}}),t.FilesVirgoSignOutView}),define("files/dev/templates/files-no-access-template",[],function(){return'
<%= title %>
<%= no_access_message %>
'}),define("files/dev/views/files-no-access-view",["core/ac-core","files/ac-files","files/templates/files-no-access-template","i18n!files/nls/ui-strings","core/views/view"],function(e,t,n,r){t.FilesNoAccessView=e.View.extend({events:{"click .files-no-access-sfs-manage-link-btn":"_onSFSManageLinkBtnClick","click .files-no-access-sign-in-link":"_onSignInLinkClick"},initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(n)},render:function(){var t=!1,n=this.options,i=n.appApi.rnaApi;return e.View.prototype.render.call(this),this.$el.children().length===0&&(i.done(_.bind(function(e){this.$el.html(this._template({title:r.FILES_NO_ACCESS_TITLE,no_access_message:r.FILES_NO_ACCESS_MESSAGE,sign_in_link:r.FILES_NO_ACCESS_SIGN_IN_LINK,sfs_manage_link_btn:r.MANAGE_DOCUMENTS_SENT_FOR_SIGNATURE}))},this)),this._initWrappers()),i.done(_.bind(function(e){e.rnaServicesAPI.isEnterpriseUser()&&!e.rnaServicesAPI.isPDFServicesEnabled()?this.$title.text()!==r.FILES_NO_ACCESS_TITLE&&(this.$title.text(r.FILES_NO_ACCESS_TITLE),this.$noAccessMsg.text(r.FILES_NO_ACCESS_MESSAGE),this.$noAccessSignInLink.text(r.FILES_NO_ACCESS_SIGN_IN_LINK)):e.rnaServicesAPI.isEnterpriseUser()&&!e.rnaServicesAPI.isEncryptionKeyValid()&&this.$title.text()!==r.ENCRYPTION_KEY_DISABLED_TITLE&&(this.$title.text(r.ENCRYPTION_KEY_DISABLED_TITLE),this.$noAccessMsg.text(r.ENCRYPTION_KEY_DISABLED_MESSAGE),this.$noAccessSignInLink.text(""))},this)),n.pluginId==="sentfiles"?i.done(_.bind(function(e){t=e.rnaServicesAPI.isEnterpriseUser()&&!e.rnaServicesAPI.isESignServicesEnabled(),t?this.$footer.hide():(this.$el.css({bottom:0}),this.$footer.show())},this)):this.$footer.hide(),this},_initWrappers:function(){this.$title=this.$(".title"),this.$content=this.$(".content"),this.$footer=this.$(".sent-files-footer"),this.$noAccessMsg=this.$(".files-no-access-message"),this.$noAccessSignInLink=this.$(".files-no-access-sign-in-link")},_onSFSManageLinkBtnClick:function(){var e=this.options;e.appApi.rnaApi.done(function(e){e.esApi.invokeMethod({methodName:"launchSFSManagePage"})})},_onSignInLinkClick:function(){var e=this.options,t=e.appApi;t.networkConnectivityApi.resetNetworkStatusToOnline({silent:!0}),t.sessionApi.signOut().then(function(){t.sessionApi.ensureSignedIn()})}})}),define("files/dev/views/files-container-view",["core/ac-core","files/ac-files","files/templates/files-container-template","core/utils/util","core/views/view","files/views/files-ipm-view","files/views/files-view","files/views/files-offline-view","files/views/files-virgo-offline-view","files/views/files-sign-out-view","files/views/files-virgo-sign-out-view","files/views/files-no-access-view"],function(e,t,n,r){return t.FilesContainerView=e.View.extend({initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(n)},render:function(){var t=this.$el;return e.View.prototype.render.call(this),t.children().length===0&&(t.html(this._template()),this._initWrappers()),this._renderChildViews(),this},_initWrappers:function(){this.$filesOfflineView=this.$(".files-offline-view"),this.$filesVirgoOfflineView=this.$(".files-virgo-offline-view"),this.$filesIpm=this.$(".files-ipm"),this.$files=this.$(".files"),this.$filesSignOut=this.$(".files-sign-out"),this.$filesVirgoSignOut=this.$(".files-virgo-sign-out"),this.$filesNoAccessView=this.$(".files-no-access-view")},_renderInDesktop:function(){return this.options.appApi.selectionApi.isRunningInFileSelection()||r.isCEF()&&this.options.appApi.saveAsApi.isRunningInFileSaveAs()?!1:!0},_renderChildViews:function(){var e=this.options;if(r.isCEF()&&(this.options.rnaRecentFilesSelect||this.options.isInSearchResultsView)){this.$files.show(),this._renderFilesView(),this.$filesOfflineView.hide(),this.$filesVirgoOfflineView.hide(),this.$filesIpm.hide(),this.$filesSignOut.hide(),this.$filesVirgoSignOut.hide(),this.$filesNoAccessView.hide();return}r.isCEF()&&!e.appApi.networkConnectivityApi.isOnline()?(this._renderInDesktop()===!1?(this.$filesOfflineView.show(),this.$filesVirgoOfflineView.hide()):(this.$filesOfflineView.hide(),this.$filesVirgoOfflineView.show()),this._renderFilesOfflineView(),this.$filesIpm.hide(),this.$files.hide(),this.$filesVirgoSignOut.hide(),this.$filesSignOut.hide(),this.$filesVirgoSignOut.hide(),this.$filesNoAccessView.hide()):this._showFilesIpmView()?(this.$filesIpm.show(),this._renderFilesIpmView(),this.$filesOfflineView.hide(),this.$filesVirgoOfflineView.hide(),this.$files.hide(),this.$filesSignOut.hide(),this.$filesVirgoSignOut.hide(),this.$filesNoAccessView.hide()):r.isCEF()?this._showFilesSignOutView()?(this._renderInDesktop()===!1?this.$filesSignOut.show():this.$filesVirgoSignOut.show(),this._renderFilesSignOutView(),this.$filesOfflineView.hide(),this.$filesVirgoOfflineView.hide(),this.$files.hide(),this.$filesIpm.hide(),this.$filesNoAccessView.hide()):this._showFilesNoAccessView()?(this.$filesNoAccessView.show(),this._renderFilesNoAccessView(),this.$filesSignOut.hide(),this.$filesVirgoSignOut.hide(),this.$filesOfflineView.hide(),this.$filesVirgoOfflineView.hide(),this.$files.hide(),this.$filesIpm.hide()):(this.$files.show(),this._renderFilesView(),this.$filesOfflineView.hide(),this.$filesVirgoOfflineView.hide(),this.$filesIpm.hide(),this.$filesSignOut.hide(),this.$filesVirgoSignOut.hide(),this.$filesNoAccessView.hide()):(this.$files.show(),this._renderFilesView(),this.$filesOfflineView.hide(),this.$filesVirgoOfflineView.hide(),this.$filesIpm.hide(),this.$filesSignOut.hide(),this.$filesVirgoSignOut.hide(),this.$filesNoAccessView.hide())},_renderFilesOfflineView:function(){this._renderInDesktop()===!1?this._renderChildView("_filesOfflineView",t.FilesOfflineView,this.$filesOfflineView):this._renderChildView("_filesVirgoOfflineView",t.FilesVirgoOfflineView,this.$filesVirgoOfflineView)},_renderFilesIpmView:function(){this._renderChildView("_filesIpmView",t.FilesIpmView,this.$filesIpm)},_renderFilesSignOutView:function(){this._renderInDesktop()===!1?this._renderChildView("_filesSignOutView",t.FilesSignOutView,this.$filesSignOut):this._renderChildView("_filesVirgoSignOutView",t.FilesVirgoSignOutView,this.$filesVirgoSignOut)},_renderFilesNoAccessView:function(){this._renderChildView("_filesNoAccessView",t.FilesNoAccessView,this.$filesNoAccessView)},_renderFilesView:function(){this._renderChildView("_filesView",t.FilesView,this.$files)},_showFilesIpmView:function(){var e=this.options,t=e.pluginId,n=e.appApi.connectorsApi,r,i,s,o=n.getConnectorPluginName(t),u;return i=n.isConnectorPlugin(t),s=n.isConnectorRemovable(t),u=n.alwaysAppearInLeftRail(o),r=n.getConnectorPluginRoot(t),!e.noUrlUpdate&&i&&s&&u&&(_.isUndefined(r)||r==="")},_showFilesSignOutView:function(){var e=this.options,t=e.pluginId,n=e.appApi.sessionApi,r=e.appApi.connectorsApi,i,s,o,u,a=r.getConnectorPluginName(t),f;return s=r.isConnectorPlugin(t),o=r.isConnectorRemovable(t),f=r.isDesktopConnector(a),u=n.isSignedInReader()&&n.isSignedIn(),i=r.getConnectorPluginRoot(t),s&&!f&&!u&&(!o||!_.isUndefined(i)&&i!=="")},_showFilesNoAccessView:function(){var e=this.options,t=e.appApi.rnaApiObj,n=e.pluginId,r=e.appApi.connectorsApi,i=r.getConnectorPluginName(n),s,o,u=!1;return s=r.isConnectorPlugin(n),o=r.isDesktopConnector(i),(!s||!o)&&t&&(u=t.rnaServicesAPI.isEnterpriseUser()&&(!t.rnaServicesAPI.isPDFServicesEnabled()||!t.rnaServicesAPI.isEncryptionKeyValid())),u}}),t.FilesContainerView}),define("files/dev/nls-cef/root/ui-strings",{SHOW:"Show",OPEN_SELECTED:"Open Selected",SAVE:"Save",NEW_FOLDER:"New Folder",UPLOAD_FILE:"Upload File",CANCEL_UPLOAD:"Cancel upload",SORT:"Sort",NO_FILES_IN_ROOT:"There are currently no files in Document Cloud.",NO_FILES_IN_CONNECTOR:"There are currently no files in <%= connector %>.",NO_FILES_IN_FOLDER:"This folder is empty.",UPLOAD_TO_ACCESS:"Upload your files to have access to them anywhere.",UNSUPPORTED_CONNECTOR_MSG:"<%= actionName %> is currently not supported for files stored in <%= connectorLabel %>.",NO_SEARCH_RESULTS:"No Search Results.",TRY_DIFFERENT_SEARCH:"Please try a different search.",NO_SEARCH_RESULTS_FOLDER:"There are no applicable files in this folder.",TOO_MANY_SEARCH_TERMS_HEADER:"Maximum search queries exceeded.",TOO_MANY_SEARCH_TERMS_MESSAGE:"Please remove some search queries to see their search results.",NEW_FOLDER_TITLE:"New Folder",NEW_FOLDER_NAME_PLACEHOLDER:"Edit New Folder Name",CREATE_FOLDER:"Create Folder",SORT_BY:"Sort by:",SORT_BY_FILE_NAME:"File Name",SORT_BY_FILE_TYPE:"File Type",SORT_BY_SIZE:"Size",SORT_BY_DATE_ADDED:"Date Added",SORT_BY_DATE_MODIFIED:"Date Modified",SORT_BY_DATE_VIEWED:"Date Viewed",DISPLAY:"Sort",VIEW_BY:"View by:",LIST:"List",THUMBNAIL:"Thumbnail",SORT_BY_FILE_SIZE:"File Size",FILTER:"Filter",FILTER_BY:"Filter by...",TAGS_TITLE:"Tags: Coming soon...",TAGS:"Tags",SEARCH_TITLE:"Search for files",CLEAR_SEARCH_TITLE:"Clear search",SEARCH_RESULTS:"Search Results ...",SEARCH_RESULTS_COUNT:"Search Results (<%= count %>)",SEARCH_RESULTS_UNAVAILABLE:"Search Results Unavailable",ADD_FILTER:"Add Filter",REMOVE_FILTER:"Remove Filter",SELECT_ATTRIBUTE:"Select Attribute",SELECT_VALUE:"Select Value",SELECT_FORMAT:"Select Format",SELECT_DATES:"Select Dates",SELECT_TOOL:"Select Tool",ENTER_VALUE:"Enter Value",EXPORT_FROM_PDF:"Export PDF",CONVERT_TO_PDF:"Create PDF",COMBINE_TO_PDF:"Combine Files",FILL_SIGN:"Fill & Sign",ADOBE_ACROBAT:"Adobe Acrobat",ADOBE_READER_MOBILE:"Adobe Reader Mobile",ADOBE_READER:"Adobe Reader",MARK_AS_FAVORITE:"Mark As Favorite",FILE_INFO:"File Info",TYPE:"Type",ADDED:"Added",MODIFIED:"Modified",PAGES:"Pages",SIZE:"Size",SHARING_LINK:"Sharing Link",UNSHARE:"unshare",MARK_AS_FAVORITE_COMING_SOON:"Mark As Favorite: Coming soon...",COMING_SOON:"Coming soon...",PREV_PAGE_TITLE:"Previous Page",NEXT_PAGE_TITLE:"Next Page",PAGE_NUM_TITLE:"Page Number",PAGE_NUM_SEPARATOR:"/",PAGE_COUNT_TITLE:"Number of Pages",SCROLL_PAGES_TITLE:"Scroll Pages",FIT_PAGE_WIDTH_TITLE:"Fit Page Width",FIT_FULL_PAGE_TITLE:"Fit Full Page",SHOW_RHP:"Show Right-Hand Panel",HIDE_RHP:"Hide Right-Hand Panel",SHOW_FILE_INFO:"Show File Info",HIDE_FILE_INFO:"Hide File Info",UNDOCK:"Undock",DOCK_TO_BOTTOM:"Dock to Bottom",ZERO_ITEMS:"0 items",ONE_FILE:"1 file",N_FILES:"<%= numFiles %> files",ONE_FOLDER:"1 folder",N_FOLDERS:"<%= numFolders %> folders",ONE_FOLDER_ONE_FILE:"1 folder, 1 file",ONE_FOLDER_N_FILES:"1 folder, <%= numFiles %> files",N_FOLDERS_ONE_FILE:"<%= numFolders %> folders, 1 file",N_FOLDERS_N_FILES:"<%= numFolders %> folders, <%= numFiles %> files",UPLOADING:"Uploading...",PROCESSING:"Processing...",SHARED:"Shared",MAKE_PUBLIC:"Make Public",MAKE_PRIVATE:"Make Private",PRIVATE:"Private",PUBLIC:"Public",SHARE_FILES_PRIVATE_TEXT:"The selected files are private and only viewable by you.",SHARE_FILE_PRIVATE_TEXT:"The selected file is private and only viewable by you.",SHARE_FILES_PUBLIC_TEXT:"The selected files are public, and anyone with the links below can view the files.",SHARE_FILE_PUBLIC_TEXT:"The selected file is public, and anyone with the link below can view the file.",SHARE_FILES_MIXED_TEXT:"The selected files include both public and private files. Click one of the buttons below to share or unshare all files.",EMAIL_BUTTON_SINGLE:"Email Link",EMAIL_BUTTON_MULTI:"Email Links",EMAIL_LINK:"Email",SAVE_BUTTON:"Close",SHARE_FILES_ERROR:"There was an error changing the sharing state of the file(s): <%= error %>",SHARE_FILES_SESSION_TIMEOUT:'Your session has expired. Click "Close" below to return to the Sign In page.',SHARE_FILE_EMAIL_BODY:"To view the file, please click on the link below:",SHARE_FILES_EMAIL_BODY:"To view the files, please click on the links below:",SHARE_FILE_EMAIL_SUBJECT:"<%= firstName %> <%= lastName %> has shared a file with you.",SHARE_FILES_EMAIL_SUBJECT:"<%= firstName %> <%= lastName %> has shared files with you.",SHARE_FILES_AV_DISALLOWED:'Sharing of the file "<%= filename %>" failed because the sharing of audio and video files is not allowed.',SHARE_FILES_SHARING_DISALLOWED:'Sharing of the file "<%= filename %>" failed because sharing the file is not allowed.',FOLDER_UPLOAD_NOT_SUPPORTED_TITLE:"Folder Upload Not Available",FOLDER_UPLOAD_NOT_SUPPORTED_MSG:"We were unable to complete your upload request. Upload of a folder is not currently supported.",FILE_UPLOAD_FAILED_TITLE:"File Upload Failed",FILE_UPLOAD_FAILED_MSG:"We were unable to complete your upload request. You may have tried to upload a file too large or a folder.",FILE_OFFLINE_TITLE:"No Internet Connection",FILE_OFFLINE_CONTENT:"Connect to the internet to view your files stored online.",FILE_OFFLINE_OK_LABEL:"Ok",FILENAME_TEXT:"File Name",RESTRICT_EDITING:"Restrict Editing",REDUCE_FILE_SIZE:"Reduce File Size",EXPORT_FILE_FORMAT:"File Format",EXPORT_SETTINGS:"Settings",EXPORT_VIEW_RESULT:"Open file after export",FILES_SIGN_OUT_TITLE:"Adobe Document Cloud",FILES_SIGN_OUT_CONTENT:"Sign in to access files",FILES_SIGN_IN_LABEL:"Sign In Now",CCLOUD_SIGN_OUT_TITLE:"Creative Cloud",CCLOUD_SIGN_OUT_CONTENT:"Sign in to access files",FILES_NO_ACCESS_TITLE:"No Access To Service",FILES_NO_ACCESS_CONTENT:"You do not have access to this service. Please contact your IT Administrator to gain access, or try to sign in with an Adobe ID."}),define("files/dev/nls-cef/ui-strings",{root:!0,"ar-ae":!0,"bg-bg":!0,"ca-es":!0,"cs-cz":!0,"da-dk":!0,"de-de":!0,"en-ae":!0,"en-gb":!0,"en-il":!0,"es-es":!0,"eu-es":!0,"fi-fi":!0,"fr-fr":!0,"fr-ma":!0,"he-il":!0,"hr-hr":!0,"hu-hu":!0,"it-it":!0,"ja-jp":!0,"ko-kr":!0,"nb-no":!0,"nl-nl":!0,"pl-pl":!0,"pt-br":!0,"ro-ro":!0,"ru-ru":!0,"sk-sk":!0,"sl-si":!0,"sl-sl":!0,"sv-se":!0,"tr-tr":!0,"uk-ua":!0,"zh-cn":!0,"zh-tw":!0}),define("files/dev/templates/page-header-template",[],function(){return'
<%= tools %>
<%= files %>
'}),define("files/dev/templates/error-template",[],function(){return'
<%= errorTitle %>
<%= errorMsg %>
'}),define("files/dev/templates/acrobat-footer-template",[],function(){return'
<%= show %>
'}),define("files/dev/templates/full-preview-home-btn-template",[],function(){return'
<%= label %>
'}),define("files/dev/all-modules",["files-unmapped/dev/ac-files","files-unmapped/dev/ac-files-init","files-unmapped/dev/views/files-header-view","files-unmapped/dev/views/folder-view","files-unmapped/dev/views/export-options-view","files-unmapped/dev/views/full-preview-view","files-unmapped/dev/views/folder-navigation-view","files-unmapped/dev/views/no-virgo-folder-items-view","files-unmapped/dev/views/filter-attr-menu-view","files-unmapped/dev/views/files-body-view","files-unmapped/dev/views/search-results-view","files-unmapped/dev/views/full-preview-plugins-selector-view","files-unmapped/dev/views/files-ipm-view","files-unmapped/dev/views/files-container-view","files-unmapped/dev/views/full-preview-action-menu-view","files-unmapped/dev/views/files-virgo-sign-out-view","files-unmapped/dev/views/file-upload-progress-view","files-unmapped/dev/views/filter-submenu-view","files-unmapped/dev/views/no-folder-items-view","files-unmapped/dev/views/virgo-files-header-view","files-unmapped/dev/views/file-save-as-options-view","files-unmapped/dev/views/files-sign-out-view","files-unmapped/dev/views/full-preview-file-info-view","files-unmapped/dev/views/full-preview-hud-view","files-unmapped/dev/views/files-virgo-offline-view","files-unmapped/dev/views/sort-menu-view","files-unmapped/dev/views/virgo-filter-file-type-menu-view","files-unmapped/dev/views/virgo-filter-navigation-view","files-unmapped/dev/views/filter-file-type-menu-view","files-unmapped/dev/views/files-offline-view","files-unmapped/dev/views/full-preview-home-btn-view","files-unmapped/dev/views/new-folder-dlg-view","files-unmapped/dev/views/search-message-view","files-unmapped/dev/views/full-preview-overlays-content-view","files-unmapped/dev/views/virgo-sort-menu-view","files-unmapped/dev/views/virgo-filter-date-menu-view","files-unmapped/dev/views/filter-added-by-menu-view","files-unmapped/dev/views/file-save-as-header-view","files-unmapped/dev/views/view-events","files-unmapped/dev/views/files-view","files-unmapped/dev/views/full-preview-plugins-content-view","files-unmapped/dev/views/search-results-summary-view","files-unmapped/dev/views/filter-menu-view","files-unmapped/dev/views/virgo-folder-navigation-view","files-unmapped/dev/views/no-search-results-view","files-unmapped/dev/views/files-footer-view","files-unmapped/dev/views/filter-date-menu-view","files-unmapped/dev/views/files-rhp-view","files-unmapped/dev/views/files-no-access-view","files-unmapped/dev/nls-cef/root/ui-strings","files-unmapped/dev/nls-cef/ui-strings","files-unmapped/dev/ops/user/saving-files-prefs-op","files-unmapped/dev/ops/user/restoring-files-prefs-op","files-unmapped/dev/ops/op-factory","files-unmapped/dev/ops/preview/getting-full-preview-metadata-op","files-unmapped/dev/ops/preview/opening-full-preview-op","files-unmapped/dev/ops/preview/toggling-full-preview-action-menu-op","files-unmapped/dev/ops/preview/creating-ngdoc-rendition-op","files-unmapped/dev/ops/preview/loading-full-preview-plugins-op","files-unmapped/dev/ops/preview/listening-for-ngdoc-job-status-op","files-unmapped/dev/ops/preview/closing-full-preview-op","files-unmapped/dev/ops/preview/selecting-full-preview-plugin-op","files-unmapped/dev/ops/creating/creating-folder-from-dlg-op","files-unmapped/dev/ops/misc/save-as-selected-collection-items-op","files-unmapped/dev/ops/misc/opening-selected-collection-items-op","files-unmapped/dev/ops/misc/navigating-to-scan-folder-op","files-unmapped/dev/ops/misc/toggling-filter-menu-op","files-unmapped/dev/ops/misc/navigating-to-acroprefs-folder-op","files-unmapped/dev/ops/misc/navigating-to-folder-op","files-unmapped/dev/ops/misc/opening-collection-item-op","files-unmapped/dev/ops/misc/changing-collection-view-op","files-unmapped/dev/ops/misc/toggling-sort-menu-op","files-unmapped/dev/ops/misc/sorting-collection-op","files-unmapped/dev/ops/listening/listening-for-selection-change-op","files-unmapped/dev/ops/listening/listening-for-search-queries-change-op","files-unmapped/dev/ops/listening/listening-for-current-folder-notifications-op","files-unmapped/dev/ops/listening/listening-for-search-invalidation-op","files-unmapped/dev/ops/listening/listening-for-file-upload-events-op","files-unmapped/dev/ops/listening/listening-for-view-events-op","files-unmapped/dev/ops/listening/listening-for-quota-errors-op","files-unmapped/dev/ops/listening/listening-for-dup-errors-op","files-unmapped/dev/ops/searching/opening-search-op","files-unmapped/dev/ops/searching/searching-op","files-unmapped/dev/ops/searching/removing-removable-queries-op","files-unmapped/dev/ops/searching/scan-closing-search-op","files-unmapped/dev/ops/searching/adding-search-field-query-op","files-unmapped/dev/ops/searching/removing-search-field-query-op","files-unmapped/dev/ops/searching/removing-type-field-query-op","files-unmapped/dev/ops/searching/closing-search-op","files-unmapped/dev/ops/searching/removing-last-field-query-op","files-unmapped/dev/ops/searching/searching-if-asked-op","files-unmapped/dev/ops/searching/scan-searching-if-asked-op","files-unmapped/dev/ops/searching/uss-searching-op","files-unmapped/dev/ops/searching/removing-name-field-query-op","files-unmapped/dev/ops/searching/removing-time-field-query-op","files-unmapped/dev/ops/acrobat/initializing-acrobat-op","files-unmapped/dev/ops/acrobat/selecting-acrobat-filter-op","files-unmapped/dev/ops/sharing/sharing-items-from-dlg-op","files-unmapped/dev/ops/sharing/sharing-item-from-panel-op","files-unmapped/dev/ops/manipulation/deleting-full-preview-item-if-confirmed-op","files-unmapped/dev/ops/dialogs/showing-new-folder-dlg-op","files-unmapped/dev/models/ui/files-ui-model","files-unmapped/dev/models/ui/sharing-ui-model","files-unmapped/dev/models/ui/ui-model-factory","files-unmapped/dev/models/model-factory","files-unmapped/dev/nls/root/ui-strings","files-unmapped/dev/nls/ui-strings","files-unmapped/dev/templates/files-template","files-unmapped/dev/templates/file-save-as-header-template","files-unmapped/dev/templates/file-save-as-options-template","files-unmapped/dev/templates/virgo-sort-menu-template","files-unmapped/dev/templates/full-preview-template","files-unmapped/dev/templates/virgo-folder-navigation-template","files-unmapped/dev/templates/virgo-filter-navigation-template","files-unmapped/dev/templates/files-footer-template","files-unmapped/dev/templates/virgo-files-header-template","files-unmapped/dev/templates/filter-added-by-menu-template","files-unmapped/dev/templates/no-folder-items-template","files-unmapped/dev/templates/full-preview-overlays-content-template","files-unmapped/dev/templates/export-options-template","files-unmapped/dev/templates/filter-file-type-menu-template","files-unmapped/dev/templates/files-virgo-offline-template","files-unmapped/dev/templates/full-preview-plugins-content-template","files-unmapped/dev/templates/filter-menu-template","files-unmapped/dev/templates/files-body-template","files-unmapped/dev/templates/filter-attr-menu-template","files-unmapped/dev/templates/folder-navigation-template","files-unmapped/dev/templates/page-header-template","files-unmapped/dev/templates/error-template","files-unmapped/dev/templates/files-offline-template","files-unmapped/dev/templates/acrobat-footer-template","files-unmapped/dev/templates/sort-menu-template","files-unmapped/dev/templates/search-results-template","files-unmapped/dev/templates/filter-date-menu-template","files-unmapped/dev/templates/files-ipm-template","files-unmapped/dev/templates/folder-template","files-unmapped/dev/templates/full-preview-hud-template","files-unmapped/dev/templates/files-rhp-template","files-unmapped/dev/templates/virgo-filter-date-menu-template","files-unmapped/dev/templates/files-container-template","files-unmapped/dev/templates/search-message-template","files-unmapped/dev/templates/full-preview-action-menu-template","files-unmapped/dev/templates/full-preview-toolbar-item-template","files-unmapped/dev/templates/no-search-results-template","files-unmapped/dev/templates/new-folder-dlg-template","files-unmapped/dev/templates/files-sign-out-template","files-unmapped/dev/templates/full-preview-file-info-template","files-unmapped/dev/templates/files-virgo-sign-out-template","files-unmapped/dev/templates/file-upload-progress-template","files-unmapped/dev/templates/files-header-template","files-unmapped/dev/templates/full-preview-home-btn-template","files-unmapped/dev/templates/files-no-access-template","files-unmapped/dev/templates/no-virgo-folder-items-template","files-unmapped/dev/templates/virgo-filter-file-type-menu-template"],function(){return undefined}),define("plugins-common/dev/ac-home-views",[],function(){var e=Ac.HomeViews;return e||(e=Ac.HomeViews={}),e}),define("plugins-common/dev/ac-tools",[],function(){var e=Ac.Tools;return e||(e=Ac.Tools={}),e}),define("plugins-common/dev/ac-full-preview-plugins",[],function(){var e=Ac.FullPreviewPlugins;return e||(e=Ac.FullPreviewPlugins={}),e}),define("plugins-common/dev/ac-account-menu-plugins",[],function(){var e=Ac.AccountMenuPlugins;return e||(e=Ac.AccountMenuPlugins={}),e}),define("plugins-common/dev/all-modules",["plugins-common-unmapped/dev/ac-home-views","plugins-common-unmapped/dev/ac-tools","plugins-common-unmapped/dev/ac-plugins","plugins-common-unmapped/dev/ac-full-preview-plugins","plugins-common-unmapped/dev/ac-account-menu-plugins"],function(){return undefined}),define("versions/framework-dev",["aicx-unmapped/dev/all-modules","app-api-unmapped/dev/app-api","core-unmapped/dev/all-modules","files-unmapped/dev/all-modules","plugins-common-unmapped/dev/all-modules"],function(){return undefined});var JSON;JSON||(JSON={}),function(){function f(e){return e<10?"0"+e:e}function quote(e){return escapable.lastIndex=0,escapable.test(e)?'"'+e.replace(escapable,function(e){var t=meta[e];return typeof t=="string"?t:"\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+e+'"'}function str(e,t){var n,r,i,s,o=gap,u,a=t[e];a&&typeof a=="object"&&typeof a.toJSON=="function"&&(a=a.toJSON(e)),typeof rep=="function"&&(a=rep.call(t,e,a));switch(typeof a){case"string":return quote(a);case"number":return isFinite(a)?String(a):"null";case"boolean":case"null":return String(a);case"object":if(!a)return"null";gap+=indent,u=[];if(Object.prototype.toString.apply(a)==="[object Array]"){s=a.length;for(n=0;n=0,n=!0,r;t&&(r=new XMLHttpRequest,n="withCredentials"in r),n||(e.ajaxPrefilter(function(e,t,n){if(e.crossDomain&&!$.isEmptyObject(e.headers)){var r={},i="";e.data&&(e.processData&&typeof e.data=="string"&&e.type==="GET"?(e.url+=(e.url.indexOf("?")===-1?"?":"&")+e.data,delete e.data):typeof e.data=="string"?i=JSON.parse(e.data):i=e.data),$.each(e.headers,function(e,t){r["CORS_"+e]=t}),r.CORS_method=e.type,r.CORS_contentType=r["CORS_Content-Type"]||e.contentType,r.__body__=i,e.data=JSON.stringify(r),e.processData=!1,e.contentType="text/plain",e.type="POST"}}),e.ajaxTransport("+*",function(t,n,r){if(t.crossDomain&&t.async){t.timeout&&(t.xdrTimeout=t.timeout,delete t.timeout);var i;return{send:function(n,r){function o(t,n,s,o){i.onload=i.onerror=i.ontimeout=e.noop,i=undefined,r(t,n,s,o)}i=new XDomainRequest,i.open(t.type,t.url),i.onload=function(){if(i.responseText.indexOf('"status":')!==-1&&i.responseText.indexOf('"headers":')!==-1&&i.responseText.indexOf('"body":')!==-1){var e=JSON.parse(i.responseText),t={200:"OK",201:"Created",202:"Accepted",204:"No Content",300:"Multiple Choices",301:"Moved Permanently",302:"Found",303:"See Other",304:"Not Modified",305:"Use Proxy",308:"Permanent Redirect",400:"Bad Request",401:"Unauthorized",403:"Forbidden",404:"Not Found",405:"Method Not Allowed",406:"Not Acceptable",407:"Proxy Authentication Required",408:"Request Timeout",409:"Conflict",410:"Gone",411:"Length Required",412:"Precondition Failed",413:"Request Entity Too Large",414:"Request-URI Too Long",415:"Unsupported Media Type",416:"Requested Range Not Satisfiable",417:"Expectation Failed",422:"Unprocessable Entity",423:"Locked",429:"Too Many Requests",431:"Request Header Fields Too Large",499:"Client Closed Request",500:"Internal Server Error",501:"Not Implemented",502:"Bad Gateway",503:"Service Unavailable",504:"Gateway Timeout"},n="";$.each(e.headers,function(e,t){n+=e+":"+t+"\n"});var r={text:JSON.stringify(e.body)},s=(t[e.status]||"").toUpperCase();o(e.status,s,r,n)}else o(200,"OK",{text:i.responseText},"Content-Type: "+i.contentType)},i.onerror=function(){o(404,"Not Found")},t.xdrTimeout?(i.ontimeout=function(){o(0,"timeout")},i.timeout=t.xdrTimeout):i.ontimeout=function(){o(408,"Request Timeout")},i.onprogress=function(){},i.send(t.hasContent&&t.data||null)},abort:function(){i&&(i.onerror=e.noop(),i.abort())}}}}))}(jQuery),define("xdr",["jquery"],function(){}),function(e){var t=8,n=function(e,t){var n=(e&65535)+(t&65535),r=(e>>16)+(t>>16)+(n>>16);return r<<16|n&65535},r=function(e,t){return e>>>t|e<<32-t},i=function(e,t){return e>>>t},s=function(e,t,n){return e&t^~e&n},o=function(e,t,n){return e&t^e&n^t&n},u=function(e){return r(e,2)^r(e,13)^r(e,22)},a=function(e){return r(e,6)^r(e,11)^r(e,25)},f=function(e){return r(e,7)^r(e,18)^i(e,3)},l=function(e){return r(e,17)^r(e,19)^i(e,10)},c=function(e,t){var r=new Array(1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298),i=new Array(1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225),c=new Array(64),h,p,d,v,m,g,y,w,E,S,x,T;e[t>>5]|=128<<24-t%32,e[(t+64>>9<<4)+15]=t;for(var E=0;E>5]|=(e.charCodeAt(i/t)&r)<<24-i%32;return n},p=function(e){var t="0123456789abcdef",n="";for(var r=0;r>2]>>(3-r%4)*8+4&15)+t.charAt(e[r>>2]>>(3-r%4)*8&15);return n},d=function(e,n){var r=h(e);r.length>16&&(r=c(r,e.length*t));var i=Array(16),s=Array(16);for(var o=0;o<16;o++)i[o]=r[o]^909522486,s[o]=r[o]^1549556828;var u=c(i.concat(h(n)),512+n.length*t);return c(s.concat(u),768)},v=function(t){return t=typeof t=="object"?e(t).val():t.toString(),t};e.extend({sha256:function(e){return e=v(e),p(c(h(e),e.length*t))},sha256hmac:function(e,t){return e=v(e),t=v(t),p(d(e,t))},sha256config:function(e){t=parseInt(e)||8}}),e.fn.sha256=function(t){e.sha256config(t);var n=v(e(this).val()),r=e.sha256(n);return e.sha256config(8),r}}(jQuery),define("jquery.sha256",["jquery"],function(){}),define("app/dev/models/ui/acrobat-ui-model",["core/ac-core","app/ac-app","core/models/ui/ui-model"],function(e,t){t.AcrobatUiModel=e.UiModel.extend({recognized:{is_in_acrobat:{type:"boolean",optional:!1},file_filters:{type:"array",optional:!1},default_filter_index:{type:"number",optional:!1},selected_filter_index:{type:"number",optional:!1},selection_type:{type:"string",optional:!1,choices:["file","folder"]},allow_multiple_selection:{type:"boolean",optional:!1},file_open_max_count:{type:"number",optional:!1}},defaults:{is_in_acrobat:!1,file_filters:[],default_filter_index:0,selected_filter_index:0,selection_type:"file",allow_multiple_selection:!0,file_open_max_count:50},initialize:function(){var t=e.Acrobat,n,r;e.UiModel.prototype.initialize.call(this),this.set("is_in_acrobat",t!==undefined);if(!this.get("is_in_acrobat"))return;n=t.fileFilters,_.each(this.filters,function(e){_.each(e.extensions,function(e,t,n){n[t]=e.toLowerCase()})}),this.set("file_filters",n),r=t.defaultFileFilter||0,this.set("default_filter_index",r),this.set("selected_filter_index",r),this.set("selection_type",t.selectionType),this.set("allow_multiple_selection",t.allowMultipleSelection)},getSelectedFilterExtensions:function(){return this.get("file_filters")[this.get("selected_filter_index")].extensions},isFolderSelectionMode:function(){return this.get("selection_type")==="folder"}})}),define("app/dev/models/ui/ajax-ui-model",["core/ac-core","app/ac-app","core/models/ui/ui-model"],function(e,t){t.AjaxUiModel=e.UiModel.extend({recognized:{ajax_spinner_threshold:{type:"number",optional:!1},ajax_transparent_threshold:{type:"number",optional:!1}},defaults:{ajax_spinner_threshold:1e3,ajax_transparent_threshold:2e3}})}),define("app/dev/models/ui/files-collection-ui-model",["core/ac-core","app/ac-app","core/models/ui/ui-model"],function(e,t){t.FilesCollectionUiModel=e.UiModel.extend({recognized:{files_collection:{type:"object",optional:!1}},defaults:{}})}),define("app/dev/models/ui/full-overlay-ui-model",["core/ac-core","app/ac-app","core/models/ui/ui-model"],function(e,t){t.FullOverlayUiModel=e.UiModel.extend({recognized:{show_overlay:{type:"boolean",optional:!1},overlay_element:{type:"object",optional:!1}},defaults:{show_overlay:!1}})}),define("app/dev/models/ui/modal-mask-ui-model",["core/ac-core","app/ac-app","core/models/ui/ui-model"],function(e,t){t.ModalMaskUiModel=e.UiModel.extend({recognized:{modal:{type:"boolean",optional:!1},modal_ajax:{type:"boolean",optional:!1},modal_transparent:{type:"boolean",optional:!1},modal_ref_count:{type:"number",optional:!1},refresh_wait:{type:"number",optional:!1}},defaults:{modal:!1,modal_ajax:!1,modal_transparent:!1,modal_ref_count:0,refresh_wait:10}})}),define("app/dev/models/ui/notification-container-ui-model",["core/ac-core","app/ac-app","core/models/ui/ui-model"],function(e,t){var n="idle",r="busy",i="complete",s="warning";t.NotificationContainerUiModel=e.UiModel.extend({recognized:{active_error_msg:{type:"object",optional:!1},mouse_leave_timeout:{type:"number",optional:!1},mouse_leave_timer:{type:"number",optional:!0},notification_items_by_category:{type:"object",optional:!1},show_download_all_by_category:{type:"object",optional:!1},net_status:{type:"string",optional:!1},show_remove_history:{type:"boolean",optional:!1},hide_error_msg:{type:"boolean",optional:!1},show_ready_map:{type:"object",optional:!1}},defaults:{active_error_msg:{},mouse_leave_timeout:400,mouse_leave_timer:undefined,notification_items_by_category:{},show_download_all_by_category:{},net_status:n,show_remove_history:!1,hide_error_msg:undefined,show_ready_map:{}},setStatusOfNotification:function(e,t,n){var r=this.get("notification_items_by_category"),i=r[n]||{};i[e]=t,r[n]=i,this.set("notification_items_by_category",r),this._updateDownloadAllStatus(n),this._updateShowReadyMap(n),this._updateRemoveHistoryStatus(),this._updateNetStatus()},removeNotification:function(e,t){var n=this.get("notification_items_by_category"),r=n[t]||{};delete r[e],this.set("notification_items_by_category",n),this._updateDownloadAllStatus(t),this._updateRemoveHistoryStatus(),this._updateNetStatus()},_updateShowReadyMap:function(e){var t=this.get("notification_items_by_category"),n=t[e]||{},r=this.get("show_ready_map"),s=0;_.each(n,function(e){e===i&&(s+=1)}),r[e]=s>=2,this.trigger("change:show_ready_map",this,r)},_updateDownloadAllStatus:function(e){var t=this.get("notification_items_by_category"),n=t[e]||{},s=this.get("show_download_all_by_category"),o=!0,u=0;_.each(n,function(e){e===i?u+=1:e===r&&(o=!1)}),s[e]=u>=2&&o,this.trigger("change:show_download_all_by_category",this,s)},_updateNetStatus:function(){var e=this.get("notification_items_by_category"),t=n,o=0;_.each(e,function(e){_.each(e,function(e,n){n=parseInt(n,10),e===r?t=r:e===s&&t!==r&&n>=o?(t=s,o=n):e===i&&t!==r&&n>=o&&(t=i,o=n)})}),this.set("net_status",t)},_updateRemoveHistoryStatus:function(){var e=this.get("notification_items_by_category"),t=!0,n=0;_.each(e,function(e){_.each(e,function(e){n+=1,e===r&&(t=!1)})}),n===0&&(t=!1),this.set("show_remove_history",t)}},{STATUS_IDLE:n,STATUS_BUSY:r,STATUS_COMPLETE:i,STATUS_WARNING:s})}),define("app/dev/models/ui/page-header-ui-model",["core/ac-core","app/ac-app","core/models/ui/ui-model"],function(e,t){t.PageHeaderUiModel=e.UiModel.extend({recognized:{show_account_menu:{type:"boolean",optional:!1},show_help_menu:{type:"boolean",optional:!1}},defaults:{show_account_menu:!1,show_help_menu:!1}})}),define("app/dev/models/ui/preferences-ui-model",["core/ac-core","app/ac-app","core/models/ui/ui-model"],function(e,t){t.PreferencesUiModel=e.UiModel.extend({recognized:{preferences:{type:"object",optional:!1}},defaults:{preferences:{}},setPreferences:function(e){var n;e.quota&&(n=e[t.APP_ID]={},_.extend(n,_.pick(e,"quota","lastToolUsed")),delete e.quota,delete e.lastToolUsed),this.set("preferences",e)},getPreferences:function(e){var t=this.get("preferences");return e&&(t=t[e]||{}),t}})}),define("app/dev/models/ui/sign-in-ui-model",["core/ac-core","app/ac-app","core/models/ui/ui-model"],function(e,t){t.SignInUiModel=e.UiModel.extend({recognized:{is_signed_in:{type:"boolean",optional:!1},is_signing_in:{type:"boolean",optional:!1},auto_sign_in:{type:"boolean",optional:!1},ims_page:{type:"string",optional:!0},ims_iframe_height:{type:"number",optional:!0},page_reload_delay:{type:"number",optional:!1},is_echosign_signed_in:{type:"boolean",optional:!1}},defaults:{is_signed_in:!1,is_signing_in:!1,auto_sign_in:!1,is_echosign_signed_in:!1,page_reload_delay:2e3},triggerAutoSignIn:function(){this.set("auto_sign_in",!0).set("auto_sign_in",!1,{silent:!0})}},{IMS_PAGE_SIGN_IN:"SignIn_Form",IMS_PAGE_FORGOT_PASSWORD_FORM:"ForgetPassword_Form",IMS_PAGE_FORGOT_PASSWORD_PAGE:"ForgetPassword_Page",IMS_PAGE_CREATE_ACCOUNT:"Create_Form",IMS_PAGE_TOU:"TOU_Display",IMS_PAGE_EMAIL_VERIFICATION:"EmailVerification_Required"})}),define("app/dev/models/ui/tuner-ui-model",["core/ac-core","app/ac-app","core/models/ui/ui-model"],function(e,t){return t.TunerUiModel=e.UiModel.extend({recognized:{disable_web_connectors:{type:"boolean",optional:!1},disable_local_connectors:{type:"boolean",optional:!1},disable_document_cloud:{type:"boolean",optional:!1}},defaults:{disable_web_connectors:!1,disable_local_connectors:!1,disable_document_cloud:!1}}),t.TunerUiModel}),define("app/dev/models/ui/window-ui-model",["core/ac-core","app/ac-app","core/models/ui/ui-model"],function(e,t){t.WindowUiModel=e.UiModel.extend({recognized:{width:{type:"number",optional:!1},height:{type:"number",optional:!1},resize_debounce_delay:{type:"number",optional:!1},font_family:{type:"string",optional:!0}},defaults:{resize_debounce_delay:250},initialize:function(){var t;e.UiModel.prototype.initialize.call(this),t=this._$window=$(window),this.set("width",t.width(),{silent:!0}),this.set("height",t.height(),{silent:!0})}})}),define("app/dev/models/ui/ui-model-factory",["core/ac-core","app/ac-app","core/models/model","app/models/ui/acrobat-ui-model","app/models/ui/ajax-ui-model","app/models/ui/files-collection-ui-model","app/models/ui/full-overlay-ui-model","app/models/ui/modal-mask-ui-model","app/models/ui/notification-container-ui-model","app/models/ui/page-header-ui-model","app/models/ui/preferences-ui-model","app/models/ui/sign-in-ui-model","app/models/ui/status-menu-ui-model","app/models/ui/tuner-ui-model","app/models/ui/window-ui-model"],function(e,t){t.UiModelFactory=e.Model.extend({create:function(e,n,r){var i=t[e];if(!!i)return new i(n,r);LOG(0,"AcApp.UiModelFactory.create: Unrecognized class: "+e)}})}),define("app/dev/templates/content-page-template",[],function(){return'
'}),define("app/dev/templates/page-header-template",[],function(){return'
<%= appName %> <%= pdfServices %>
'}),define("app/dev/templates/account-menu-template",[],function(){return''}),define("app/dev/views/account-menu-plugins-view",["core/ac-core","app/ac-app","core/templates/account-menu-item-template","core/utils/sc-analytics","core/views/plugins-selector-view"],function(e,t,n,r){t.AccountMenuPluginsView=e.PluginsSelectorView.extend({initialize:function(){e.PluginsSelectorView.prototype.initialize.call(this),this.options=_.extend({},this.options,{pluginsUiModel:this.options.accountMenuPluginsUiModel})},render:function(){e.PluginsSelectorView.prototype.render.call(this)},_getSelectorTemplate:function(){return n},_getSelectorViewEvent:function(){return t.ViewEvents.ACCOUNT_MENU_ITEM_CLICK},_logSiteCatalystEvent:function(e){this.options.appApi.siteCatalystApi.logScEvent([r.TOP_HEADER,r.USER_ACCOUNT_MENU,e[0]])},_onPluginSelectorClick:function(t){var n=this.options,r=n.appApi;r.dialogApi.closeAllDialogs(),r.pluginsApi.callPluginMethodForEachIfEnabled(n.accountMenuPluginsUiModel.getAllIds(),"deselectPlugin",undefined,undefined,!0),_.delay(_.bind(function(){e.PluginsSelectorView.prototype._onPluginSelectorClick.call(this,t)},this),n.accountMenuPluginsUiModel.get("deselect_delay"))}})}),define("app/dev/views/account-menu-view",["core/ac-core","core/ac-core-config","app/ac-app","app/templates/account-menu-template","i18n!app/nls/ui-strings","core/views/view","core/views/menu-view","app/views/account-menu-plugins-view"],function(e,t,n,r,i){n.AccountMenuView=e.MenuView.extend({events:function(){return _.extend({},e.MenuView.prototype.events,{"click .account-menu-footer-item.privacy":"_onPrivacyClick","click .account-menu-footer-item.terms":"_onTermsClick","click .account-menu-footer-item.cookies":"_onCookiesClick"})},initialize:function(){e.MenuView.prototype.initialize.call(this)},render:function(){var n;e.MenuView.prototype.render.call(this),n=this.$el,n.children().length===0&&(n.html(_.template(r)({privacy:i.PRIVACY,terms:i.TERMS,cookies:i.COOKIES,privacyUrl:this._getOpenUrl(t.PRIVACY_URL,t.PRIVACY_URL_LOC),termsUrl:this._getOpenUrl(t.TERMS_URL,t.TERMS_URL),cookiesUrl:this._getOpenUrl(t.COOKIES_URL,t.COOKIES_URL_LOC)})),this._initWrappers()),this._renderChildViews()},open:function(){var t=e.MenuView.prototype.open.call(this);return this.$el.addClass("shown"),t},close:function(){e.MenuView.prototype.close.call(this,undefined,{doNotEmpty:!0}),this.$el.removeClass("shown")},_onPrivacyClick:function(e){e.preventDefault(),this.close(),window.open(this._getOpenUrl(t.PRIVACY_URL,t.PRIVACY_URL_LOC))},_onTermsClick:function(e){e.preventDefault(),this.close(),window.open(this._getOpenUrl(t.TERMS_URL,t.TERMS_URL_LOC))},_onCookiesClick:function(e){e.preventDefault(),this.close(),window.open(this._getOpenUrl(t.COOKIES_URL,t.COOKIES_URL_LOC))},_getOpenUrl:function(e,t){var n=this.options.appApi.localeApi.getLocale();return n!=="en-us"&&n!=="root"&&(e=_.template(t,{locale:n==="en-gb"?"uk":n.substr(3)})),e},_initWrappers:function(){e.MenuView.prototype._initWrappers.call(this),this.$menuItems=this.$(".account-menu-items"),this.$menuSep=this.$(".account-menu-sep"),this.$menuFooter=this.$(".account-menu-footer")},_renderChildViews:function(){this._renderAccountMenuPluginsView()},_renderAccountMenuPluginsView:function(){this._renderChildView("_accountMenuPluginsView",n.AccountMenuPluginsView,this.$menuItems)},_closedByClick:function(t){e.MenuView.prototype._closedByClick.call(this,t),this._consumeEvent(t)}})}),define("app/dev/templates/help-menu-template",[],function(){return'
'}),define("app/dev/views/help-menu-view",["core/ac-core","app/ac-app","app/templates/help-menu-template","i18n!app/nls/ui-strings","core/utils/sc-analytics","core/views/view","core/views/menu-view"],function(e,t,n,r,i){return t.HelpMenuView=e.MenuView.extend({events:function(){return _.extend({},e.MenuView.prototype.events,{"click .ask-us-menu-item":"_onAskUsClick","click .support-menu-item":"_onSupportClick","click .about-menu-item":"_onAboutClick"})},initialize:function(){e.MenuView.prototype.initialize.call(this),this._template=_.template(n)},render:function(){e.MenuView.prototype.render.call(this),this.$el.children().length===0&&this.$el.html(this._template({askUs:r.ASK_US_A_QUESTION,support:r.SUPPORT,aboutApp:r.ABOUT_APP})),this._initWrappers()},open:function(){var t=e.MenuView.prototype.open.call(this);return this.$el.addClass("shown"),t},close:function(){e.MenuView.prototype.close.call(this),this.$el.removeClass("shown")},_closedByClick:function(t){e.MenuView.prototype._closedByClick.call(this,t),this._consumeEvent(t)},_onMenuItemClick:function(){var e=this.options,t=e.appApi;t.dialogApi.closeAllDialogs(),t.pluginsApi.callPluginMethodForEachIfEnabled(e.accountMenuPluginsUiModel.getAllIds(),"deselectPlugin",undefined,undefined,!0),_.defer(this.close)},_onAskUsClick:function(e){this._onMenuItemClick(e),this.options.appApi.siteCatalystApi.logScEvent([i.TOP_HEADER,i.HELP_MENU,i.ASK_US]),_.defer(_.bind(function(){this._triggerViewEvent(t.ViewEvents.ASK_US_CLICK)},this))},_onSupportClick:function(e){this._onMenuItemClick(e),this.options.appApi.siteCatalystApi.logScEvent([i.TOP_HEADER,i.HELP_MENU,i.SUPPORT]),this._triggerViewEvent(t.ViewEvents.SUPPORT_CLICK)},_onAboutClick:function(e){this._onMenuItemClick(e),this.options.appApi.siteCatalystApi.logScEvent([i.TOP_HEADER,i.HELP_MENU,i.ABOUT_PRODUCT]),this._triggerViewEvent(t.ViewEvents.ABOUT_CLICK,{parentView:t.viewMgr,triggerEl:this.options.triggerEl})}}),t.HelpMenuView}),define("app/dev/templates/status-menu-template",[],function(){return'
'}),define("app/dev/templates/status-menu-item-template",[],function(){return'
'}),define("app/dev/views/status-menu-tooltip-view",["core/ac-core","app/ac-app","core/utils/css-util","core/views/menu-view"],function(e,t,n){var r={};return t.StatusMenuTooltipView=e.MenuView.extend({events:function(){return _.extend({},e.MenuView.prototype.events,{mouseenter:"_onMouseEnter",mouseleave:"_onMouseLeave"})},initialize:function(){e.MenuView.prototype.initialize.call(this),this._addUiModelEventListeners()},render:function(){e.MenuView.prototype.render.call(this),this.$text||this._initWrappers(),this.$text.html(this.options.statusMenuUiModel.getActiveTooltipHtml()),this.$(e.ScAnalytics.ANALYTICS_SELECTOR).trigger(e.ScAnalytics.RENDER)},open:function(t){e.MenuView.prototype.open.call(this,t),this._positionTooltip()},close:function(t,n){e.MenuView.prototype.close.call(this,t,_.extend({},n,{doNotEmpty:!0}))},_initWrappers:function(){e.MenuView.prototype._initWrappers.call(this),this.$nub=this.$(".status-menu-tooltip-nub"),this.$text=this.$(".status-menu-tooltip-text")},_positionTooltip:function(){var e=this.$el,t,r,i=this.options.statusMenuUiModel,s=i.getActiveTooltipElement();if(!s)return;t=s.offset(),r=this.$nub,e.offset({top:t.top+n.getFullHeight(s)+r.height(),left:t.left+n.getFullWidth(s)-n.getFullWidth(e)})},_onMouseEnter:function(){this._clearMouseLeaveTimer()},_onMouseLeave:function(e){this._startMouseLeaveTimer(e)},_addUiModelEventListeners:function(){this.listenTo(this.options.statusMenuUiModel,"change:tooltips",this._onTooltipsChange)},_onTooltipsChange:function(){var e=this.options.statusMenuUiModel.get("tooltips"),t;_.each(r,function(e){e.purge=!0}),_.each(e,_.bind(function(e,n){t=r[n],t||(t=r[n]={tooltip:e},e.element.on("mouseenter",this._onTooltipElementMouseEnter).on("mouseleave",this._onTooltipElementMouseLeave).data("tooltip_id",n)),t.purge=!1},this)),_.each(r,_.bind(function(e,t){e.purge&&(e.tooltip.element.off("mouseenter",this._onTooltipElementMouseEnter).off("mouseleave",this._onTooltipElementMouseLeave).removeData("tooltip_id"),delete r[t])},this))},_onTooltipElementMouseEnter:function(e){this._clearMouseLeaveTimer(),this.options.statusMenuUiModel.set("active_tooltip_id",$(e.target).data("tooltip_id")),this.isMenuOpen()?(this._positionTooltip(),this.render()):this.open()},_onTooltipElementMouseLeave:function(e){this._startMouseLeaveTimer(e)},_startMouseLeaveTimer:function(){var e=this.options.statusMenuUiModel;this._clearMouseLeaveTimer(),e.set("mouse_leave_timer",setTimeout(_.bind(function(){e.unset("active_tooltip_id"),this.close()},this),e.get("mouse_leave_timeout")))},_clearMouseLeaveTimer:function(){var e=this.options.statusMenuUiModel,t=e.get("mouse_leave_timer");t&&(clearTimeout(t),e.unset("mouse_leave_timer"))}}),t.StatusMenuTooltipView}),define("app/dev/views/status-menu-view",["core/ac-core","app/ac-app","app/templates/status-menu-template","app/templates/status-menu-item-template","i18n!app/nls/ui-strings","core/utils/css-util","core/utils/event-util","core/utils/view-util","core/utils/sc-analytics","core/views/menu-view","app/views/status-menu-tooltip-view"],function(e,t,n,r,i,s,o,u,a){var f=Ac.Plugins.types.tools.plugin_ids;t.StatusMenuView=e.MenuView.extend({events:function(){return _.extend({},e.MenuView.prototype.events,{"click .status-menu-remove-history-btn":"_onRemoveHistoryClick"})},initialize:function(){e.MenuView.prototype.initialize.call(this),this._addDomEventListeners(),this._addUiModelEventListeners(),this._addAppApiCallbacks()},render:function(){var t=this.$el,o=t.width(),a,l,c,h,p=u.isElementEmpty(t),d=this.options.statusMenuUiModel,v=d.get("menu_item_by_id"),m=d.get("menu_item_shown"),g,y;if(!p&&!this.isMenuOpen())return this;e.MenuView.prototype.render.call(this),p&&(t.html(_.template(n)({removeHistory:i.REMOVE_HISTORY})),this._initWrappers()),a=this.$menuItems,a.children().length===0&&_.each(f,function(e){a.append(_.template(r)()),l=a.children().last(),l.width(o-s.getExtraWidth(l)),d.get("menu_item_by_id")[e]=l}),_.each(v,function(e,t){m[t]?(g=!0,e.show()):e.hide()}),y=d.hasCompletedItem(),h=this.$removeHistory,y?h.show():h.hide(),c=a.children(),d.getNumShownItems()===1&&!y?c.addClass("no-border"):c.removeClass("no-border"),a.css("max-height",d.get("max_height_frac")*(this.$body.height()-t.parent().height())+"px"),g?t.show():t.hide(),this._renderChildViews()},open:function(){var t=this.options,n=t.appApi,r=t.statusMenuUiModel,i=this.$menuItems;return clearTimeout(this._timeoutId),t.fullOverlayUiModel.get("show_overlay")?(r.set("show_menu",!1,{silent:!0}),this._getResolvedPromise()):this.isMenuOpen()?this._getResolvedPromise():(n.siteCatalystApi.logScEvent([a.PROGRESS_STATUS_MENU,a.SHOWN]),e.MenuView.prototype.open.call(this,function(){var e,t,n;i.addClass("scrollable"),n=r.get("scroll_to_id"),n?(t=r.get("menu_item_by_id"),e=t[n],e&&i.scrollTop(e.position().top)):i.scrollTop(0),r.statusMenuIsDisplayed()}))},close:function(){var n=this.options,r=this._tooltipView;if(!this.isMenuOpen())return;this.stopListening(),this.$menuItems.removeClass("scrollable"),e.MenuView.prototype.close.call(this,_.bind(function(){n.appApi.siteCatalystApi.logScEvent([a.PROGRESS_STATUS_MENU,a.HIDDEN]),this._triggerViewEvent(t.ViewEvents.STATUS_MENU_CLOSED),n.statusMenuUiModel.statusMenuIsClosed(),this._addUiModelEventListeners()},this),{doNotEmpty:!0}),r&&r.close()},_initWrappers:function(){e.MenuView.prototype._initWrappers.call(this),this.$body=$("body"),this.$menuItems=this.$(".status-menu-items"),this.$tooltip=this.$(".status-menu-tooltip"),this.$removeHistory=this.$(".status-menu-remove-history-btn")},_renderChildViews:function(){this._renderChildView("_tooltipView",t.StatusMenuTooltipView,this.$tooltip)},_onRemoveHistoryClick:function(){var e=this.options,n=t.StatusMenuUiModel,r=e.statusMenuUiModel,i=r.get("status_by_id"),s=e.appApi.pluginsApi;e.appApi.siteCatalystApi.logScEvent([a.PROGRESS_STATUS_MENU,a.REMOVE_HISTORY,a.CLICKED]),_.each(f,function(e){if(!s.getPluginApi(e))return!1;i[e]!==n.STATUS_BUSY&&(r.setStatus(e,n.STATUS_IDLE).hideMenuItem(e),s.callPluginMethod(e,"removeStatusHistory"))}),r.getNetStatus()===n.STATUS_BUSY&&this.render()},_addDomEventListeners:function(){var e=this.$el.get(0);o.addDomEventListener(e,"dragover",this._consumeEvent,!1).addDomEventListener(e,"dragenter",this._consumeEvent,!1).addDomEventListener(e,"drop",this._consumeEvent,!1)},_addUiModelEventListeners:function(){var e=this.options,t=e.statusMenuUiModel,n=e.fullOverlayUiModel;this.listenTo(t,"change:net_status",this._onNetStatusChange).listenTo(t,"change:menu_item_shown",this._onMenuItemShownChange).listenTo(t,"change:scroll_to_id",this._onScrollToIdChange).listenTo(n,"change:show_overlay",this._onShowOverlayChange)},_onNetStatusChange:function(e,n){var r=t.StatusMenuUiModel,i=this.options.statusMenuUiModel;n===r.STATUS_IDLE?i.set("show_menu",!1):(i.set("show_menu",!0),this.render())},_onMenuItemShownChange:function(){var e=this.options.statusMenuUiModel,t=_.debounce(_.bind(function(){this.options.statusMenuUiModel.isOneMenuItemShown()?this.open():this.close()},this),e.get("menu_item_shown_delay"));t()},_onScrollToIdChange:function(){this.render()},_onShowOverlayChange:function(e,t){t&&this.close()},_addAppApiCallbacks:function(){this.options.appApi.routerApi.addHistoryChangeCallback(this._onHistoryChange)},_onHistoryChange:function(){this.close()}})}),define("app/dev/views/page-header-view",["core/ac-core","app/ac-app","app/templates/page-header-template","i18n!app/nls/ui-strings","core/utils/util","core/utils/css-util","core/utils/truncate","core/utils/view-util","core/utils/sc-analytics","core/views/view","app/views/account-menu-view","app/views/help-menu-view","app/views/status-menu-view"],function(e,t,n,r,i,s,o,u,a){return t.PageHeaderView=e.View.extend({events:{"click .adc-logo":"_onAdcLogoClick","click .adc-app-name":"_onAdcAppNameClick","click .account-menu-btn":"_onAccountMenuBtnClick","click .help-menu-btn":"_onHelpMenuBtnClick","click .status-menu-btn":"_onStatusMenuBtnClick"},initialize:function(){e.View.prototype.initialize.call(this),this._addAppApiCallbacks(),this._addUiModelEventListeners(),this._addKeyEventListener()},render:function(){var t=this._getUserFirstName();return e.View.prototype.render.call(this),this.$el.children().length===0?(this.$el.html(_.template(n)({appName:e.Config.APP_NAME_DC,pdfServices:r.PDF_SERVICES,userName:t,helpMenuTitle:r.HELP})),this._initWrappers()):this.$userName.text(t),this._renderChildViews(),this._positionHelpMenu(),this._positionStatusMenu(),this._updateStatusMenuButton(),this._truncateUserName(),this},_getUserFirstName:function(){var e=this.options.usersMeModel.get("identity"),t;return e&&(t=e.first_name),t||r.ACCOUNT},_initWrappers:function(){this.$body=$("body"),this.$appTitle=this.$(".adc-app-title"),this.$accountMenuBtn=this.$(".account-menu-btn"),this.$helpMenuBtn=this.$(".help-menu-btn"),this.$userName=this.$(".user-name"),this.$accountMenu=this.$(".account-menu"),this.$helpMenu=this.$(".help-menu"),this.$helpMenuTitle=this.$(".help-menu-title"),this.$statusMenuBtn=this.$(".status-menu-btn"),this.$statusMenuBtnIcon=this.$(".status-menu-btn-icon"),this.$statusMenuBtnLabel=this.$(".status-menu-btn-label"),this.$statusMenu=this.$(".status-menu")},_onViewEvent:function(e,n){if(e===t.ViewEvents.STATUS_MENU_CLOSED){this.options.statusMenuUiModel.set("show_menu",!1);return}this.trigger(e,n)},_getStatusTooltip:function(){var e=this.options.statusMenuUiModel.getNetStatus();return e===t.StatusMenuUiModel.STATUS_BUSY?r.SHOW_PROGRESS:r.PROGRESS_COMPLETE},_updateStatusMenuButton:function(){var e=this.$statusMenuBtn,n=this.$statusMenuBtnIcon,r=this.$statusMenuBtnLabel,i=t.StatusMenuUiModel,s=this.options.statusMenuUiModel,o=s.getNetStatus(),u=this._getStatusTooltip();n.removeClass("warning busy selected"),o===i.STATUS_IDLE?e.addClass("hidden"):(o===i.STATUS_BUSY?n.addClass("busy"):o===i.STATUS_WARNING&&n.addClass("warning"),s.get("show_menu")&&n.addClass("selected"),e.removeClass("hidden")),e.attr("title",u),r.text(u)},_truncateUserName:function(){var e=this.$appTitle,t=this.$userName,n;n=this.$el.width()-(e.position().left+e.width())-this.$statusMenuBtn.width()-this.$helpMenuBtn.width()-s.getExtraWidth(this.$userName),n>0&&t.css("max-width",n),o.truncateElementText(t)},_renderChildViews:function(){this._renderAccountMenuView(),this._renderHelpMenuView(),this._renderStatusMenuView()},_renderAccountMenuView:function(){this._renderChildView("_accountMenuView",t.AccountMenuView,this.$accountMenu,{animate:!1})},_renderHelpMenuView:function(){this._renderChildView("_helpMenuView",t.HelpMenuView,this.$helpMenu,{animate:!1})},_renderStatusMenuView:function(){this._renderChildView("_statusMenuView",t.StatusMenuView,this.$statusMenu)},_getSiteCatalystContext:function(){return a.TOP_HEADER},_positionHelpMenu:function(){var e=this.$helpMenuBtn,t=e.position();this._helpMenuView.$el.css("right",this.$el.width()-t.left-s.getFullWidth(e)-5+"px")},_positionStatusMenu:function(){var e=this.$statusMenuBtn,t=e.position();if(u.isElementHidden(e))return;this._statusMenuView.$el.css("right",this.$el.width()-t.left-s.getFullWidth(e)-2+"px")},_showAccountMenu:function(e){var t=this.options,n=this.$accountMenuBtn,r=this._accountMenuView;e?(n.addClass("pressed"),r.open().always(function(){t.pageHeaderUiModel.set("show_account_menu",!1)})):(n.removeClass("pressed"),r.close())},_showHelpMenu:function(e){var t=this.options,n=this.$helpMenuBtn,r=this._helpMenuView;e?(n.addClass("pressed"),r.open().always(function(){t.pageHeaderUiModel.set("show_help_menu",!1)})):(n.removeClass("pressed"),r.close())},_selectFilesTool:function(){var e=this.options.appApi,t=e.pluginsApi;e.dialogApi.closeAllDialogs(),t.callPluginMethodForEachIfEnabled(t.getPluginTypeConfig("account_menu").plugin_ids,"deselectPlugin",undefined,undefined,!0),e.previewApi.closeFullPreview({noHistoryEffect:!0}).then(function(){e.routerApi.navigate("folder/"+encodeURIComponent(e.folderApi.getRootFolderId()),{trigger:!0})})},_navigateToApollo:function(){var t;e.Features.isFeatureEnabled("redirect_to_apollo")?(t=e.Features.getFeature("apollo_url"),t?window.location=t:LOG("AcApp.PageHeaderView._navigateToApollo could not get apollo_url")):this._selectFilesTool()},_onAdcLogoClick:function(t){this._logSiteCatalystEvent([a.ACOM_TREFOIL,a.CLICKED]),!i.isCEF()&&t.shiftKey&&e.Features.isFeatureEnabled("no_collection_item_checkbox")&&this.options.appApi.routerApi.hasQueryParam("no_collection_item_checkbox","1")?this.options.appApi.selectionApi.selectFiles("home",{dialog:{singleFileSelection:!0},plugin:{filter:{extensions:[".pdf"]}}}).done(function(e){LOG("AcApp.PageHeaderView._onAdcLogoClick localFiles: "+e.localFiles.length+" uploadedFiles: "+_.keys(e.uploadedFileAttrs).length)}):this._navigateToApollo()},_onAdcAppNameClick:function(){this._logSiteCatalystEvent([a.A_DOT_COM,a.CLICKED]),this._navigateToApollo()},_onAdcAppNameKeyDown:function(e){return e.which===13||e.which===32?(this._consumeEvent(e),$(e.target).click(),!0):!1},_onKeyDown:function(e){var t=$(e.target),n=!1;return u.descendantHasFocus(this.$el)?(t.is(this.$accountMenuBtn)?n=this._onAccountMenuBtnKeyDown(e):t.is(this.$helpMenuBtn)?n=this._onHelpMenuBtnKeyDown(e):t.is(this.$statusMenuBtn)?n=this._onStatusMenuBtnKeyDown(e):this.$(".adc-app-name").is(t)&&(n=this._onAdcAppNameKeyDown(e)),n):n},_onMenuBtnKeyDown:function(e,t){var n=e.which,r=e.target,i=!1;switch(n){case 32:case 38:case 40:this._consumeEvent(e);if(n===38&&t||n!==38&&!t)r.click(),i=!0}return i},_onAccountMenuBtnClick:function(){this._logSiteCatalystEvent([a.USER_ACCOUNT_MENU,a.CLICKED]),this._triggerViewEvent(t.ViewEvents.ACCOUNT_MENU_BTN_CLICK)},_onAccountMenuBtnKeyDown:function(e){return this._onMenuBtnKeyDown(e,this.options.pageHeaderUiModel.get("show_account_menu"))},_onHelpMenuBtnClick:function(){this._logSiteCatalystEvent([a.HELP,a.CLICKED]),this._triggerViewEvent(t.ViewEvents.HELP_MENU_BTN_CLICK)},_onHelpMenuBtnKeyDown:function(e){return this._onMenuBtnKeyDown(e,this.options.pageHeaderUiModel.get("show_help_menu"))},_onStatusMenuBtnClick:function(){this.options.statusMenuUiModel.set("show_menu",!0)},_onStatusMenuBtnKeyDown:function(e){return this._onMenuBtnKeyDown(e,this.options.statusMenuUiModel.get("show_menu"))},_addAppApiCallbacks:function(){this.options.appApi.windowApi.addWindowResizeCallback(this.render)},_addUiModelEventListeners:function(){var e=this.options,t=e.fullOverlayUiModel,n=e.pageHeaderUiModel,r=e.statusMenuUiModel,i=e.usersMeModel;this.listenTo(n,"change:show_account_menu",this._onShowAccountMenuChange).listenTo(n,"change:show_help_menu",this._onShowHelpMenuChange).listenTo(i,"change:identity",this._onIdentityChange).listenTo(r,"change:net_status",this._onNetStatusChange).listenTo(r,"change:show_menu",this._onShowStatusMenuChange).listenTo(t,"change:show_overlay",this._onShowOverlayChange)},_onShowAccountMenuChange:function(e,t){this._showAccountMenu(t)},_onShowHelpMenuChange:function(e,t){this._showHelpMenu(t)},_onIdentityChange:function(){this.render()},_onNetStatusChange:function(){this._updateStatusMenuButton()},_onShowStatusMenuChange:function(e,t){var n=this._statusMenuView,r=this.options.statusMenuUiModel;t?n.isMenuOpen()||n.open().always(function(){r.set("show_menu",!1)}):n.close(),this.render()},_onShowOverlayChange:function(e,t){var n=this.$statusMenuBtn;t?n.addClass("disabled").attr("disabled","disabled"):n.removeClass("disabled").removeAttr("disabled")}}),t.PageHeaderView}),define("app/dev/templates/tools-template",[],function(){return'
'}),define("app/dev/views/toolbar-view",["core/ac-core","app/ac-app","core/templates/toolbar-item-template","core/utils/css-util","core/utils/view-util","core/utils/sc-analytics","core/views/plugins-selector-view"],function(e,t,n,r,i,s){t.ToolbarView=e.PluginsSelectorView.extend({initialize:function(){e.PluginsSelectorView.prototype.initialize.call(this),this._addAppApiCallbacks(),this._addUiModelEventListeners()},render:function(){e.PluginsSelectorView.prototype.render.call(this),r.fitInOneRow(this.$selectors,this.$labels,{prefFontSize:16,minFontSize:12,prefLrPadding:12}),this._positionPointer()},_getSelectorTemplate:function(){return n},_getSelectorViewEvent:function(){return t.ViewEvents.TOOLBAR_ITEM_CLICK},_getSiteCatalystContext:function(){return s.TOOLS},_initWrappers:function(){e.PluginsSelectorView.prototype._initWrappers.call(this),this.$labels=this.$(".toolbar-item-label"),this.$pointer=this.$(".toolbar-selection-pointer"),this.$toolsContent=this.$el.parent().find(".tools-content")},_adjustItemLabelFontSize:function(){function h(){o.css("font-size",u+"px"),o.css("padding","0 "+l+"px")}var e=this.$el,t=this.$selectors,n=t.last(),s=n.position(),o=this.$labels,u=16,a=12,f=!1,l=12,c;if(i.isElementHidden(e))return;h();while(s){if(s.top===0)break;u-=1,l-=1,h(),s=n.position();if(u<=a){f=!0;break}}f&&s.top>0?c=e.width()/t.length-r.getExtraWidth(t.eq(0)):c="none",t.css("max-width",c)},_positionPointer:function(){var e=this._getSelectedSelectorElement(),t,n=this.$pointer,i;if(e){if(!e.is(":visible"))return;n.width(e.find(".toolbar-item-label").width()),i=r.getFullWidth(e),t=e.position(),n.show().css("left",t.left+1+(i-n.width())/2+"px")}else n.hide()},_addAppApiCallbacks:function(){this.options.appApi.windowApi.addWindowResizeCallback(this.render)},_addUiModelEventListeners:function(){this.listenTo(this.options.toolsUiModel,"change:plugins",this.render)}})}),define("app/dev/templates/tool-content-template",[],function(){return'
'}),define("app/dev/views/tools-content-view",["core/ac-core","app/ac-app","app/templates/tool-content-template","core/views/plugins-content-view"],function(e,t,n){t.ToolsContentView=e.PluginsContentView.extend({_getContentTemplate:function(){return n}})}),define("app/dev/views/full-overlay-view",["core/ac-core","app/ac-app","core/views/view"],function(e,t){t.FullOverlayView=e.View.extend({initialize:function(){e.View.prototype.initialize.call(this),this._addUiModelEventListeners()},render:function(){e.View.prototype.render.call(this),this.options.fullOverlayUiModel.set("overlay_element",this.$el)},_addUiModelEventListeners:function(){this.listenTo(this.options.fullOverlayUiModel,"change:show_overlay",this._onShowOverlayChange)},_onShowOverlayChange:function(e,t){var n=this.$el;t?n.addClass("shown"):n.removeClass("shown")}})}),define("app/dev/views/tools-view",["core/ac-core","app/ac-app","core/utils/util","app/templates/tools-template","core/views/view","app/views/toolbar-view","app/views/tools-content-view","app/views/full-overlay-view"],function(e,t,n,r){t.ToolsView=e.View.extend({initialize:function(){e.View.prototype.initialize.call(this),this._addUiModelEventListeners(),this._addAppApiCallbacks()},render:function(){var t=this.$el;e.View.prototype.render.call(this),t.children().length===0&&(t.html(_.template(r)()),this._initWrappers()),this._renderChildViews()},_initWrappers:function(){this.$navigation=this.$(".tools-navigation"),this.$toolbar=this.$(".toolbar"),this.$toolsContent=this.$(".tools-content"),this.$fullOverlay=this.$(".full-overlay").first()},_renderChildViews:function(){var e=_.extend({},this.options,{pluginsUiModel:this.options.toolsUiModel});this._renderChildView("_toolsContentView",t.ToolsContentView,this.$toolsContent,e),this._renderChildView("_toolbarView",t.ToolbarView,this.$toolbar,e),e.noToolbar&&(this.$toolsContent.offset({top:this.$toolbar.offset().top}),this.$toolbar.hide()),this._renderChildView("_fullOverlayView",t.FullOverlayView,this.$fullOverlay,e)},_addUiModelEventListeners:function(){var e=this.options;this.listenTo(e.toolsUiModel,"change:selected_plugin_id",this._onSelectedPluginIdChange),this.listenTo(e.fullOverlayUiModel,"change:show_overlay",this._onShowOverlayChange)},_onSelectedPluginIdChange:function(){this.render()},_addAppApiCallbacks:function(){this.options.appApi.previewApi.addItemModelChangeCallback(this._onFullPreviewModelChange)},_onFullPreviewModelChange:function(e){this._toggleOverlay(!!e)},_onShowOverlayChange:function(e,t){this._toggleOverlay(t)},_toggleOverlay:function(e){var t=this.$navigation.add(this.$toolsContent),r="hidden";n.isCEF()?this._toolbarView.render():e?t.addClass(r).attr("aria-hidden",!0):(t.removeClass(r).removeAttr("aria-hidden"),this._toolbarView.render())}})}),define("app/dev/views/acrobat-footer-view",["core/ac-core","files/ac-files","app/ac-app","files/templates/acrobat-footer-template","i18n!core/nls/ui-strings","i18n!files/nls/ui-strings","core/utils/view-util","core/views/view"],function(e,t,n,r,i,s,o){var u='';n.AcrobatFooterView=e.View.extend({events:{"change .acrobat-file-filter":"_onFileFilterChange","click .acrobat-open-selected":"_onOpenSelectedClick","click .acrobat-cancel":"_onCancelClick"},initialize:function(){var t=$("body");e.View.prototype.initialize.call(this),this._template=_.template(r),t.addClass("acrobat"),this._filterMenuItemTemplate=_.template(u),t.on("keydown",this._onBodyKeyDown),this._addAppApiCallbacks()},render:function(){e.View.prototype.render.call(this),this.$el.children().length===0&&(this.$el.html(this._template({show:s.SHOW,cancel:i.CANCEL})),this._initWrappers(),this._renderFilterMenu()),this._updateControls(),this._updateFilterMenu()},_initWrappers:function(){this.$fileFilterMenu=this.$(".acrobat-file-filter"),this.$openSelectedBtn=this.$(".acrobat-open-selected"),this.$cancelBtn=this.$(".acrobat-cancel")},_renderFilterMenu:function(){var e,t,n,r;e=this.options.acrobatUiModel.get("file_filters"),t=this.$fileFilterMenu,r=this._filterMenuItemTemplate,_.each(e,function(e){t.append(r({display:e.display})),n=t.children().last(),n.attr("value",e.extensions)})},_updateFilterMenu:function(){var e,t;e=this.options.acrobatUiModel.get("selected_filter_index"),t=this.$fileFilterMenu.children(),t.removeAttr("selected"),t.eq(e).attr("selected","selected")},_updateControls:function(){var e=this.options,t=this.$openSelectedBtn,n=e.appApi.selectionApi.getSelectedItemModels(),r=n.length;e.acrobatUiModel.isFolderSelectionMode()?(t.attr("value",r>0?s.OPEN_SELECTED:s.SAVE),o.enableInput(t,!0)):(t.attr("value",s.OPEN_SELECTED),o.enableInput(t,r>0))},_onFileFilterChange:function(e){this._triggerViewEvent(n.ViewEvents.ACROBAT_SELECT_FILTER,{filterIndex:e.target.selectedIndex})},_onOpenSelectedClick:function(){var e=this.options,r=e.appApi,i=r.selectionApi,s,o,u;s=i.getSelectedItemModels();if(e.acrobatUiModel.isFolderSelectionMode()&&(!s||s.length===0)){this._triggerViewEvent(n.ViewEvents.ACROBAT_OPEN,{ids:[e.folderApi.getCurrentFolderId()]});return}if(!s)return;o=[],_.each(s,function(e){o.push(e.id);if(!u&&e.isFolder())return u=e,!1}),u?this._triggerViewEvent(t.ViewEvents.NAVIGATE_TO_FOLDER,{id:u.get("id")}):this._triggerViewEvent(n.ViewEvents.ACROBAT_OPEN,{ids:o})},_onCancelClick:function(){this._triggerViewEvent(n.ViewEvents.ACROBAT_CLOSE)},_onBodyKeyDown:function(e){var t=e.which;if(o.isElementHidden(this.$el))return;t===13?this._onOpenSelectedClick():t===27&&this._onCancelClick()},_addAppApiCallbacks:function(){this.options.appApi.selectionApi.addSelectedItemsModelsChangeCallback(this._onSelectionChange)},_onSelectionChange:function(){this._updateControls()}})}),define("app/dev/views/modal-mask-view",["core/ac-core","app/ac-app","core/utils/util","core/views/view"],function(e,t,n){t.ModalMaskView=e.View.extend({initialize:function(){e.View.prototype.initialize.call(this),this._addUiModelEventListeners()},render:function(){return e.View.prototype.render.call(this),this._updateModal(),this},_updateModal:function(){var e=this.$el,t=this.options,r=t.appApi,i=t.modalMaskUiModel,s=r.selectionApi;if(!e)return;r.displayApi.isDebugLogging()&&LOG("AcApp.ModalMaskView._updateModal modal: "+i.get("modal")+", modal_ajax: "+i.get("modal_ajax")+", modal_transparent: "+i.get("modal_transparent")+", modal_ref_count: "+i.get("modal_ref_count")),i.get("modal")?(e.not(".shown").addClass("shown").prevAll().each(function(e,t){var n=$(t),r=n.data("ariaHidden"),i=n.attr("aria-hidden");i!==undefined&&r===undefined&&n.data("ariaHidden",i),(!i||i==="false")&&n.attr("aria-hidden","true")}),i.get("modal_ajax")&&(!n.isCEF()||!s.isRunningInFileSelection())?e.addClass("ajax"):e.removeClass("ajax"),i.get("modal_transparent")&&(!r.dialogApi.isDialogOpen()||s.isRunningInFileSelection())?e.addClass("transparent"):e.removeClass("transparent")):i.get("modal_ref_count")===0&&(e.filter(".shown").prevAll().each(function(e,t){var n=$(t),r=n.data("ariaHidden");r!==undefined?n.attr("aria-hidden",r).removeData("ariaHidden"):n.removeAttr("aria-hidden")}),e.removeClass("shown ajax transparent"))},_addUiModelEventListeners:function(){var e=this.options.modalMaskUiModel;e.on("change",_.debounce(_.bind(function(){this._onModalChange()},this),e.get("refresh_wait")))},_onModalChange:function(){this._updateModal()}})}),define("app/dev/views/content-page-view",["core/ac-core","app/ac-app","app/templates/content-page-template","app/views/page-header-view","app/views/tools-view","app/views/acrobat-footer-view","app/views/modal-mask-view"],function(e,t,n){t.ContentPageView=e.View.extend({initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(n)},render:function(){return e.View.prototype.render.call(this),this.$el.children().length===0&&(this.$el.html(this._template()),this._initWrappers()),this._renderChildViews(),this},_initWrappers:function(){this.$header=this.$(".page-header"),this.$tools=this.$(".tools"),this.$fullPreview=this.$(".page-body.full-preview"),this.$acrobatFooter=this.$(".acrobat-footer"),this.$modalMask=$("#modal-mask")},_renderChildViews:function(){this._renderPageHeaderView(),this._renderToolsView(),this._renderAcrobatFooterView(),this._renderModalMaskView()},_renderPageHeaderView:function(){this._renderChildView("_pageHeaderView",t.PageHeaderView,this.$header)},_renderToolsView:function(){this._renderChildView("_toolsView",t.ToolsView,this.$tools)},_renderAcrobatFooterView:function(){this.options.acrobatUiModel.get("is_in_acrobat")&&this._renderChildView("_acrobatFooterView",t.AcrobatFooterView,this.$acrobatFooter)},_renderModalMaskView:function(){this._renderChildView("_modalMaskView",t.ModalMaskView,this.$modalMask)}})}),define("app/dev/templates/rhp-content-page-template",[],function(){return'
'}),define("app/dev/templates/rhp-container-template",[],function(){return'
'}),define("app/dev/views/rhp-container-view",["core/ac-core","app/ac-app","files/ac-files","app/templates/rhp-container-template","core/views/view"],function(e,t,n,r){t.RHPContainerView=e.View.extend({events:{},initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(r)},render:function(){return e.View.prototype.render.call(this),this.$el.children().length===0&&(this.$el.html(this._template({})),this._initWrappers()),this._renderChildViews(),this},_initWrappers:function(){this.$pluginsContent=this.$(".rhp-container-content")},_renderChildViews:function(){var e=this.options;this._renderChildView("_pluginsContentView",n.FullPreviewPluginsContentView,this.$pluginsContent,_.extend(e,{pluginsUiModel:e.runningInContextBoard?e.fullPreviewRhpPluginsUiModel:e.fullPreviewPluginsUiModel}))}})}),define("app/dev/views/rhp-content-page-view",["core/ac-core","app/ac-app","app/templates/rhp-content-page-template","app/views/rhp-container-view"],function(e,t,n){t.RHPContentPageView=e.View.extend({initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(n)},render:function(){return e.View.prototype.render.call(this),this.$el.children().length===0&&(this.$el.html(this._template()),this._initWrappers()),this._renderChildViews(),this},_initWrappers:function(){this.$rhpContainer=this.$(".rhp-main-container"),$("body").css("overflow","hidden")},_renderChildViews:function(){this.$rhpContainer.show(),this._renderRHPContainerView()},_renderRHPContainerView:function(){this._renderChildView("_rhpContainerView",t.RHPContainerView,this.$rhpContainer)}})}),define("app/dev/templates/notification-content-page-template",[],function(){return'
'}),define("app/dev/templates/notification-error-view-template",[],function(){return'
<%= title %>
<%= description %>
<%= retry %>
'}),define("app/dev/views/notification-error-view",["core/ac-core","app/templates/notification-error-view-template","i18n!core/nls/ui-strings","core/views/view"],function(e,t,n){var r=e.View.extend({initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(t),this._addUiModelEventListeners(),this.render()},events:{mouseleave:"_startMouseLeaveTimer",mouseenter:"_clearMouseLeaveTimer","click .error-retry":"_onRetryClick"},render:function(){return e.View.prototype.render.call(this),this.$el.html(_.template(t)({title:"",description:"",retry:n.NOTIFICATION_RETRY})),this._initWrappers(),this},show:function(e,t){var n=e,r="",i=!1,s;try{s=JSON.parse(e)}catch(o){}s&&(n=s.errorTitle,r=s.errorBody,i=s.showRetry),this.$errorTitle.text(n),this.$errorDesc.text(r),this.$el.show(),i?this.$retry.show():this.$retry.hide(),this.$el.css("top",t.offset().top+15),this.$errorTitle.offset().top+this.$errorTitle.height()+this.$errorDesc.height()>this.$notificationParent.height()&&this.$notificationParent.height(this.$notificationParent.height()+this.$errorTitle.offset().top+this.$errorTitle.height()+this.$errorDesc.height()+10-this.$notificationParent.height()),this.options.notificationContainerUiModel.set("hide_error_msg",!1)},close:function(){this.$errorTitle.text(""),this.$errorDesc.text(""),this.notificationView=null,this.$el.hide(),this.$notificationParent.height("auto")},_initWrappers:function(){this.$errorTitle=this.$(".error-title"),this.$errorDesc=this.$(".error-description"),this.$retry=this.$(".error-retry"),this.$notificationParent=$(".notification-content-container")},_startMouseLeaveTimer:function(){var e=this.options.notificationContainerUiModel;this._clearMouseLeaveTimer(),e.set("mouse_leave_timer",setTimeout(_.bind(function(){e.unset("active_error_msg"),this.close()},this),e.get("mouse_leave_timeout")))},_clearMouseLeaveTimer:function(){var e=this.options.notificationContainerUiModel,t=e.get("mouse_leave_timer");t&&(clearTimeout(t),e.unset("mouse_leave_timer"))},_onRetryClick:function(e){this._consumeEvent(e),this.notificationView.retryDownload(),this.options.notificationContainerUiModel.unset("active_error_msg"),this.close()},_onActiveErrorChange:function(e,t){if(t&&t.error&&t.error.length){var n=t.error,r=t.elem;this.notificationView=t.view,this.show(n,r)}},_onHideErrorMsgChange:function(e,t){t&&this._startMouseLeaveTimer()},_addUiModelEventListeners:function(){this.listenTo(this.options.notificationContainerUiModel,"change:active_error_msg",this._onActiveErrorChange),this.listenTo(this.options.notificationContainerUiModel,"change:hide_error_msg",this._onHideErrorMsgChange)}});return r}),define("app/dev/templates/notification-subcontainer-template",[],function(){return'
<%= title %>
'}),define("app/dev/templates/notification-template",[],function(){return'
<%= filename %>
<%= error %>
<%= filename %>
<%= progress_state %>
<%= filename %>
<%= progress_state %>
'}),define("app/dev/views/notification-view",["core/ac-core","app/ac-app","core/utils/util","core/utils/truncate","app/templates/notification-template","i18n!core/nls/ui-strings","core/models/rna/rna-notification-model","core/utils/sc-analytics","core/views/view"],function(e,t,n,r,i,s,o,u){var a=15;t.NotificationView=e.View.extend({initialize:function(t,n){e.View.prototype.initialize.call(this),this._template=_.template(i),this.options=n,this.options.appApi.displayApi.showSpinner(!1)},events:{"click .notification-view":"_onNotificationViewClick","keydown .notification-view":"_onNotificationViewKeydown","click .cancel-upload":"_onCancelUploadClick","keydown .cancel-upload":"_onNotificationViewKeydown","mouseenter .notification-error-msg":"_onErrorMouseEnter","mouseleave .notification-error-msg":"_onErrorMouseLeave","mouseenter .notification-view":"_onNotificationViewEnter","focusin .notification-view":"_onNotificationViewEnter","mouseleave .notification-view":"_onNotificationViewLeave","focusout .notification-view":"_onNotificationViewLeave"},_onNotificationViewClick:function(e){var t=this.model.get("state");t===o.NOTIFICATION_STATES.DOWNLOADED?this._onShowInFolderClick(e):t===o.NOTIFICATION_STATES.COMPLETED?this._onDownloadClick(e):t===o.NOTIFICATION_STATES.DONE&&this._consumeEvent(e)},_onNotificationViewKeydown:function(e){if(e.which===13||e.which===32)this._consumeEvent(e),$(e.target).click()},_logAnalytics:function(e){if(this.siteCatalystName){var t=[u.TOOLS,this.siteCatalystName,u.PROGRESS_BAR];this.options.appApi.siteCatalystApi.logScEvent(t.concat(e))}},_onDownloadClick:function(e){e&&this._consumeEvent(e),this._logAnalytics([u.DOWNLOAD_CLICK,u.SAVE_AS,u.CLICKED]);var t={fileName:this.convertedFileName,fileExtension:this.fileExtn,showCustomSaveDialog:!0,allowNewFolder:!0},n=_.extend(this.options,{assetId:this.outputID});this.fileExtn.toLowerCase()==="pdf"?(n=_.extend(n,{fileName:""}),this._downloadFileInternal(n)):this.options.appApi.rnaApi.done(_.bind(function(e){e.getFileSaveAsLocation(t).then(_.bind(function(e){console.log(e),e.destFileSys=="BlueHeronFS"?(n=_.extend(n,{fileName:""}),this._downloadFileInternal(n,!1,!0,e.destFileName,e.destFilePath)):(n=_.extend(n,{fileObj:e.destFileProxyObj}),this._downloadFileInternal(n,e.isNative,!1,e.destFileName))},this),_.bind(function(e){if(e!==7){var t={errorTitle:s.NOTIFICATION_DOWNLOAD_ERROR,errorBody:"",downloadError:!0,showRetry:!0};this.model.invoke("setProperty",{operationType:"",state:o.NOTIFICATION_STATES.FAILED,error:JSON.stringify(t)})}else this.model.invoke("setProperty",{operationType:"",state:o.NOTIFICATION_STATES.COMPLETED})},this))},this))},_downloadFileInternal:function(t,n,r,i,u){var a=e.opFactory.create("DownloadingFileOp",t).run();a[1].done(_.bind(function(e){e.errorSet||(e.downloadedFileName?this.downloadedFileName=e.downloadedFileName:this.downloadedFileName=i,this.model.invoke("setProperty",{operationType:o.NOTIFICATION_OPERATIONS.DOWNLOAD,state:o.NOTIFICATION_STATES.IN_PROGRESS}))},this)),a[0].then(_.bind(function(a){this.downloadedFile=a.downloadedFile;var f={},l=this.downloadClickAction||o.DOWNLOAD_LINK_CLICK_ACTION.SAVE_FILE,c=n?o.NOTIFICATION_STATES.DOWNLOADED:o.NOTIFICATION_STATES.DONE,h=this.fileExtn.toLowerCase()==="pdf"?o.NOTIFICATION_STATES.COMPLETED:c;this.downloadedFile||(h=o.NOTIFICATION_STATES.COMPLETED),a.downloadedFileSys&&(f.downloadedFileSys=a.downloadedFileSys),a.downloadedFilePath&&(f.downloadedFilePath=a.downloadedFilePath),this._updateUserData(f),r?this._uploadToBH(this.downloadedFile,u,i).then(_.bind(function(){this.model.invoke("setProperty",{operationType:"",state:h})},this),_.bind(function(){var e={errorTitle:s.NOTIFICATION_DOWNLOAD_ERROR,errorBody:"",downloadError:!0,showRetry:!0};this.model.invoke("setProperty",{operationType:"",state:o.NOTIFICATION_STATES.FAILED,error:JSON.stringify(e)})},this)):(this.model.invoke("setProperty",{operationType:"",state:h}),this.downloadedFile&&l===o.DOWNLOAD_LINK_CLICK_ACTION.OPEN_FILE&&this.fileExtn.toLowerCase()==="pdf"&&(t=_.extend(this.options,{localFileModel:this.downloadedFile,displayName:this.convertedFileName,needSave:!0,updateRecentFilesAndFolders:!1}),e.opFactory.create("OpeningDocInReaderOp",t).run()))},this),_.bind(function(e){if(e!==7){var t={errorTitle:s.NOTIFICATION_DOWNLOAD_ERROR,errorBody:"",downloadError:!0,showRetry:!0};this.model.invoke("setProperty",{operationType:"",state:o.NOTIFICATION_STATES.FAILED,error:JSON.stringify(t)})}else this.model.invoke("setProperty",{operationType:"",state:o.NOTIFICATION_STATES.COMPLETED})},this))},_uploadToBH:function(t,r,i){function s(e,t){n.isIE9orBelow()?this.model.set({progress:-1}):this.model.set({progress:parseInt(e/t*100,10)})}var o=_.extend(this.options,{rnaFile:t,uploadType:"managed",parentID:r,fileName:i,onDuplicateName:"auto_rename",notificationObj:this.model.get("notification"),progressCB:_.bind(s,this),ignoreContentType:!0,showBezel:!1});return e.opFactory.create("UploadingFileOp",o).run()},retryDownload:function(){this.model.invoke("setProperty",{operationType:"",state:o.NOTIFICATION_STATES.COMPLETED,error:""}).done(_.bind(function(){this._onNotificationViewClick()},this))},_onErrorMouseEnter:function(){this.options.notificationContainerUiModel.set("active_error_msg",{error:this.model.get("error"),elem:this.$el,view:this}),this._logAnalytics([u.ERROR,u.HOVER_OVER,u.SHOWN])},_onErrorMouseLeave:function(){this.options.notificationContainerUiModel.set("hide_error_msg",!0)},_onNotificationViewEnter:function(){var e=this.model.get("state"),t=this.$notificationView.width(),n=this.$downloadLink.width()+a;if(e===o.NOTIFICATION_STATES.COMPLETED||e===o.NOTIFICATION_STATES.DOWNLOADED)this.$notificationView.addClass("hover"),e===o.NOTIFICATION_STATES.COMPLETED&&(this.category!=="create"&&this.category!=="export"&&this.category!=="combineconvert"&&this.$downloadLink.text(s.SHOW_IN_FOLDER),n=this.$downloadLink.width()+a,r.truncateElementText(this.$fileName,t-n))},_onNotificationViewLeave:function(){var e=this.model.get("state"),t=this.$notificationView.width(),n=this.$downloadLink.width()+a;if(e===o.NOTIFICATION_STATES.COMPLETED||e===o.NOTIFICATION_STATES.DOWNLOADED)this.$notificationView.removeClass("hover"),e===o.NOTIFICATION_STATES.COMPLETED&&(this.$downloadLink.text(this.onNotificationLeaveText),n=this.$downloadLink.width()+a,r.truncateElementText(this.$fileName,t-n))},_updateStatus:function(){var e=this._getState();this.options.notificationContainerUiModel.setStatusOfNotification(this.notificationID,e,this.category)},_updateUserData:function(e){var t=this.model.get("userData"),n={},r={};try{n=JSON.parse(t)}catch(i){}r=$.extend(!0,{},n,e),this.model.invoke("setProperty",{userData:JSON.stringify(r)})},_onCancelUploadClick:function(){this._logAnalytics([u.UPLOAD_CANCELLED,u.CLICKED]),this.model.invoke("customNotification",{eventName:"stopFileUpload",eventData:""})},_onShowInFolderClick:function(e){var t;e&&this._consumeEvent(e),this._logAnalytics([u.DOWNLOAD_COMPLETE,u.SHOW_IN_FOLDER,u.CLICKED]),this.downloadedFile?(t={fileObj:this.downloadedFile},this.options.appApi.rnaApi.done(function(e){e.fileApi({methodName:"showFileInFinderOrExplorer",methodArgs:t})})):this.downloadedFileSys&&this.downloadedFilePath?(t={fileSys:this.downloadedFileSys,filePath:this.downloadedFilePath},this.options.appApi.rnaApi.done(function(e){e.fileApi({methodName:"showFileInFinderOrExplorer",methodArgs:t})})):this.model.invoke("setProperty",{operationType:"",state:o.NOTIFICATION_STATES.COMPLETED})},render:function(){e.View.prototype.render.call(this);var t=this.model,r=t.get("progressPercentage"),o=t.get("description"),u=t.get("userData"),a=t.get("operationType"),f=t.get("state"),l,c=t.get("error"),h,p="",d,v;this.notificationID=t.get("notificationID"),this.category=o;try{l=JSON.parse(u)}catch(m){}return l&&(p=l.customMessage,this.fileName=l.fileName||"",this.fileExtn=l.fileExtn||"",this.siteCatalystName=l.siteCatalystName||"",this.convertedFileName="",this.fileName&&(h=n.getExtension(this.fileName),h?this.convertedFileName=this.fileName.slice(0,-h.length)+this.fileExtn:this.convertedFileName=this.fileName+"."+this.fileExtn),l.outputID&&(this.outputID=l.outputID),this.downloadClickAction=l.downloadClickAction,this.canUploadBeCancelled=l.canUploadBeCancelled),this.onNotificationLeaveText=this.fileExtn.toLowerCase()==="pdf"?s.OPEN:s.SAVE_AS,this.$el.html(_.template(i)({progress:r,filename:p||this.fileName,download:this.onNotificationLeaveText,progress_state:s.NOTIFICATION_UPLOADING,error:s.NOTIFICATION_CONVERSION_FAILURE})),this._initWrappers(),this._updateStatus(),this.canUploadBeCancelled||this.$cancelUpload.hide(),this._addEventListeners(),this._onProgressChange(t,r),this._onStatusChange(t,f),this._onOperationChange(t,a),this._onErrorChange(t,c),this._onUserDataChange(t,u),this},truncateTextToFit:function(){var e=this.$notificationView.width(),t=this._getProgressStateWidth()+30,n=this.$downloadLink.width()+a,i=this.$errorMsg.width()+a;r.truncateElementText(this.$progressFileNameUpload,e-t),r.truncateElementText(this.$progressFileNameBusy,e-t),r.truncateElementText(this.$fileName,e-Math.max(n,i))},truncateFileNameTextToFit:function(){var e=this.$notificationView.width(),t=this.$downloadLink.width()+a;r.truncateElementText(this.$fileName,e-t)},close:function(){this.options.notificationContainerUiModel.removeNotification(this.notificationID,this.category),this.remove()},refresh:function(){this.render()},_initWrappers:function(){this.$progressMeter=this.$(".progress-meter"),this.$progressView=this.$(".progress-view"),this.$progressUploadBar=this.$(".progress-upload-bar"),this.$progressBusyBar=this.$(".progress-busy-bar"),this.$progressState=this.$(".progress-state"),this.$downloadLink=this.$(".notification-download-link"),this.$errorMsg=this.$(".notification-error-msg"),this.$fileName=this.$(".notification-file-name"),this.$progressFileNameUpload=this.$(".progress-file-name.upload"),this.$progressFileNameBusy=this.$(".progress-file-name.busy"),this.$cancelUpload=this.$(".cancel-upload"),this.$notificationView=this.$(".notification-view")},_setProgress:function(e){if(this.$progressMeter.length){var t=this.$(".progress-upload-bar").width()/100;this.$progressMeter.width(t*e)}},_onProgressChange:function(e,t){this._setProgress(t)},_onStatusChange:function(e,t){var n=this.$notificationView.width(),i;t===o.NOTIFICATION_STATES.COMPLETED&&(this.$progressView.hide(),this.$downloadLink.show(),this.$downloadLink.text(this.onNotificationLeaveText),this.$fileName.text(this.convertedFileName),i=this.$downloadLink.width()+a,r.truncateElementText(this.$fileName,n-i),this.$fileName.show(),this._logAnalytics([u.COMPLETE,u.SHOWN])),t===o.NOTIFICATION_STATES.DOWNLOADED&&(this.$progressView.hide(),this.$downloadLink.show(),this.$fileName.text(this.downloadedFileName||this.convertedFileName),this.$downloadLink.text(s.SHOW_IN_FOLDER),i=this.$downloadLink.width()+a,r.truncateElementText(this.$fileName,n-i),this.$fileName.show(),this._logAnalytics([u.DOWNLOAD_COMPLETE,u.SHOWN])),t===o.NOTIFICATION_STATES.DONE&&(this.$progressView.hide(),this.$downloadLink.show(),this.$notificationView.removeClass("hover"),this.$fileName.text(this.downloadedFileName||this.convertedFileName),this.fileExtn.toLowerCase()!=="pdf"&&(this.$downloadLink.text(s.SAVED),this.$downloadLink.css("text-decoration","none"),this.$downloadLink.css("cursor","default")),i=this.$downloadLink.width()+a,r.truncateElementText(this.$fileName,n-i),this.$fileName.show(),this._logAnalytics([u.DOWNLOAD_COMPLETE,u.SHOWN])),t===o.NOTIFICATION_STATES.IN_PROGRESS&&(this.$progressView.show(),this.$notificationView.removeClass("hover")),t===o.NOTIFICATION_STATES.FAILED&&(this.$progressView.hide(),this.$downloadLink.hide(),this.$fileName.show(),this.$notificationView.removeClass("hover"),this._logAnalytics([u.CONVERT_FAILED,u.SHOWN])),this._updateStatus()},_getState:function(){var e=t.NotificationContainerUiModel.STATUS_BUSY,n=this.model.get("state");return n===o.NOTIFICATION_STATES.COMPLETED||n===o.NOTIFICATION_STATES.DONE||n===o.NOTIFICATION_STATES.DOWNLOADED?e=t.NotificationContainerUiModel.STATUS_COMPLETE:n===o.NOTIFICATION_STATES.FAILED&&(e=t.NotificationContainerUiModel.STATUS_WARNING),e},_onOperationChange:function(e,t){var n=this.$notificationView.width(),i;t===o.NOTIFICATION_OPERATIONS.UPLOAD?(i=this._getProgressStateWidth()+30,r.truncateElementText(this.$progressFileNameUpload,n-i),this.$progressUploadBar.show(),this.$fileName.hide(),this.$progressBusyBar.hide(),this._logAnalytics([u.UPLOADING,u.SHOWN])):t===o.NOTIFICATION_OPERATIONS.CONVERT?(this._logAnalytics([u.UPLOAD_COMPLETE,u.SHOWN]),this.$progressState.text(s.NOTIFICATION_CONVERTING),i=this._getProgressStateWidth()+a,this.$progressUploadBar.hide(),this.$fileName.hide(),this.$progressBusyBar.show(),r.truncateElementText(this.$progressFileNameBusy,n-i),this._logAnalytics([u.CONVERTING,u.SHOWN])):t===o.NOTIFICATION_OPERATIONS.DOWNLOAD?(this.$downloadLink.hide(),this.$progressState.text(s.NOTIFICATION_DOWNLOADING),i=this._getProgressStateWidth()+a,this.$progressUploadBar.hide(),this.$fileName.hide(),this.$progressBusyBar.show(),this.$progressFileNameBusy.text(this.downloadedFileName||this.convertedFileName),r.truncateElementText(this.$progressFileNameBusy,n-i),this._logAnalytics([u.DOWNLOADING,u.SHOWN])):t===o.NOTIFICATION_OPERATIONS.PROCESS&&(this.$downloadLink.hide(),this.$progressState.text(s.NOTIFICATION_PROCESSING),i=this._getProgressStateWidth()+a,this.$progressUploadBar.hide(),this.$fileName.hide(),this.$progressBusyBar.show(),this.$progressFileNameBusy.text(this.downloadedFileName||this.convertedFileName),r.truncateElementText(this.$progressFileNameBusy,n-i))},_getProgressStateWidth:function(){var e=$(this.$progressState[0]).width(),t=$(this.$progressState[1]).width();return e&&t?Math.max(e,t):e||t},_onUserDataChange:function(e,t){var n;try{n=JSON.parse(t)}catch(r){}n&&n.outputID&&(this.outputID=n.outputID),n&&n.downloadedFileName&&(this.downloadedFileName=n.downloadedFileName),n&&n.downloadedFileSys&&(this.downloadedFileSys=n.downloadedFileSys),n&&n.downloadedFilePath&&(this.downloadedFilePath=n.downloadedFilePath)},_onErrorChange:function(e,t){var n,i=this.$notificationView.width(),o;try{n=JSON.parse(t)}catch(u){}n&&(n.errorTitle||n.errorBody)?(n.downloadError===!0?this.$errorMsg.text(s.NOTIFICATION_DOWNLOAD_FAILURE):this.$errorMsg.text(s.NOTIFICATION_CONVERSION_FAILURE),o=this.$errorMsg.width()+a,r.truncateElementText(this.$fileName,i-o),this.$progressView.hide(),this.$errorMsg.show(),this.$fileName.show()):this.$errorMsg.hide()},_onShowReadyMapChange:function(e,t){this.model.get("state")===o.NOTIFICATION_STATES.COMPLETED&&(t[this.category]?this.onNotificationLeaveText=s.READY:this.onNotificationLeaveText=this.fileExtn.toLowerCase()==="pdf"?s.OPEN:s.SAVE_AS,this.$downloadLink.text(this.onNotificationLeaveText))},_addEventListeners:function(){this.model.on("change:progressPercentage",this._onProgressChange,this),this.model.on("change:state",this._onStatusChange,this),this.model.on("change:userData",this._onUserDataChange,this),this.model.on("change:operationType",this._onOperationChange,this),this.model.on("change:error",this._onErrorChange,this),this.model.on("remove",this.close,this),this.listenTo(this.options.notificationContainerUiModel,"change:show_ready_map",this._onShowReadyMapChange)}})}),define("app/dev/views/notification-subcontainer-view",["core/ac-core","app/ac-app","app/templates/notification-subcontainer-template","core/models/rna/rna-notification-model","i18n!core/nls/ui-strings","core/utils/sc-analytics","app/views/notification-view","core/views/view"],function(e,t,n,r,i,s){t.NotificationSubcontainerView=e.View.extend({initialize:function(t){e.View.prototype.initialize.call(this),this._template=_.template(n),this.category=t.category,this.siteCatalystName=t.siteCatalystName,this.showDownloadAll=t.showDownloadAll,this.title=t.title,this.notificationCollection=t.collection,this._addEventListeners()},events:{"click .notification-download-all-link":"_onDownloadAllClick"},render:function(){e.View.prototype.render.call(this),this.$el.html(_.template(n)({title:this.title,download:i.DOWNLOAD_ALL})),this._initWrappers();var t=this.options.notificationContainerUiModel;return t.get("show_download_all_by_category")[this.category]&&this.showDownloadAll?this.$downloadAll.show():this.$downloadAll.hide(),this},close:function(){this.remove()},createNotificationView:function(e){var n=new t.NotificationView({model:e},this.options);return this.addChildView(n),this.$notificationViewContainer.append(n.render().el),n.truncateTextToFit(),n},_initWrappers:function(){this.$notificationViewContainer=this.$(".notification-view-container"),this.$downloadAll=this.$(".notification-download-all-link")},_addEventListeners:function(){this.listenTo(this.options.notificationContainerUiModel,"change:show_download_all_by_category",this._onDownloadAllStausChange)},_onDownloadAllStausChange:function(e,t){t[this.category]&&this.showDownloadAll?this.$downloadAll.show():this.$downloadAll.hide()},_getFilteredNotificationCollection:function(){var e=this.category,t=this.notificationCollection.filter(function(t){return t.get("description")===e});return t},_getDownloadAssetIdArray:function(){var e=this._getFilteredNotificationCollection(),t=[];return e.forEach(function(e){var n=e.get("userData"),r=JSON.parse(n);r.outputID&&t.push(r.outputID)},this),t},_onDownloadAllClick:function(t){var n=this._getDownloadAssetIdArray(),i=n.join(";"),o={notificationHeading:this.title},u;this._consumeEvent(t),this.siteCatalystName&&(u=[s.TOOLS,this.siteCatalystName,s.PROGRESS_BAR,s.DOWNLOAD_CLICK,s.ALL_BUTTON,s.CLICKED],this.options.appApi.siteCatalystApi.logScEvent(u)),this.options.appApi.sessionApi.ensureSignedIn().done(_.bind(function(){this.options.appApi.rnaApi.done(_.bind(function(t){o.fileName="binder.zip",o.fileExtn="zip",t.notificationAPI.createNotification({operationType:r.NOTIFICATION_OPERATIONS.PROCESS,state:r.NOTIFICATION_STATES.IN_PROGRESS,userData:JSON.stringify(o),progress:0,description:this.category}).done(_.bind(function(t){e.opFactory.create("DownloadingZipStartOp",_.extend({},this.options,{id_list:i,numForms:0,fileName:"binder.zip",notificationObj:t})).run().then(_.bind(function(e){this._onDownloadCompletion(t,e)},this),_.bind(function(e){this._onDownloadFailed(t,e)},this))},this))},this))},this))},_onDownloadCompletion:function(e,t){var n=e.get("userData"),i={};try{i=JSON.parse(n)}catch(s){}t.downloadedFileSys&&(i.downloadedFileSys=t.downloadedFileSys),t.downloadedFilePath&&(i.downloadedFilePath=t.downloadedFilePath),e.invoke("setProperty",{operationType:"",userData:JSON.stringify(i),state:r.NOTIFICATION_STATES.DOWNLOADED})},_onDownloadFailed:function(e,t){if(t!==7){var n={errorTitle:i.NOTIFICATION_DOWNLOAD_ERROR,errorBody:"",downloadError:!0,showRetry:!1};e.invoke("setProperty",{operationType:"",state:r.NOTIFICATION_STATES.FAILED,error:JSON.stringify(n)})}}})}),define("app/dev/views/notification-content-page-view",["core/ac-core","app/ac-app","i18n!app/nls/ui-strings","app/templates/notification-content-page-template","app/views/notification-error-view","core/models/rna/rna-notification-model","core/views/view","app/views/notification-subcontainer-view"],function(e,t,n,r,i,s){t.NotificationContentPageView=e.View.extend({initialize:function(){e.View.prototype.initialize.call(this),this._template=_.template(r),this.notificationSubContainerMap={},this.options.appApi.rnaApi.done(_.bind(function(e){this.notificationCollection=e.notificationAPI.getNotificationList(),this._addEventListeners()},this)),this.options.appApi.sessionApi.addSignedInChangeCallback(this._onSignedInChange),this.hasBeenAdjustedOnScrollAdd=!1,this._addUiModelEventListeners(),this.options.appApi.displayApi.applyUIThemeStyles(this.$el).then(_.bind(function(){_.delay(_.bind(function(){this.render()},this),0)},this))},_onSignedInChange:function(e,t){t||this._removeAllNotifications()},_addUiModelEventListeners:function(){var e=this.options,t=e.notificationContainerUiModel;this.listenTo(t,"change:net_status",this._onNetStatusChange)},_onNetStatusChange:function(e,n){n===t.NotificationContainerUiModel.STATUS_COMPLETE?this._showNotificationProgressWidget(!0,"completed"):n===t.NotificationContainerUiModel.STATUS_BUSY?this._showNotificationProgressWidget(!0,"busy"):n===t.NotificationContainerUiModel.STATUS_WARNING?this._showNotificationProgressWidget(!0,"warning"):n===t.NotificationContainerUiModel.STATUS_IDLE&&this._showNotificationProgressWidget(!1,"")},_showNotificationProgressWidget:function(e,t){this.options.appApi.rnaApi.done(_.bind(function(n){n.rnaServicesAPI.showServicesProgressWidget(e,!1,t,!0)},this))},events:{"click .notification-remove-history-button":"_onRemoveHistoryClick","keydown .notification-remove-history-button":"_onRemoveHistoryKeyDown"},render:function(){return e.View.prototype.render.call(this),this.$el.children().length===0&&(this.$el.html(_.template(r)({remove_history:n.REMOVE_HISTORY})),this._initWrappers(),this.notificationCollection&&this._renderChildViews()),this.options.notificationContainerUiModel.get("show_remove_history")===!1?this.$notificationClearButton.hide():this.$notificationClearButton.show(),this},_initWrappers:function(){this.$notificationContainer=this.$(".notification-container"),this.$notificationErrorView=this.$(".notification-error-view"),this.$notificationClearButton=this.$(".notification-remove-history-button")},_renderChildViews:function(){var e=this;this.notificationCollection.each(function(t){e._addNewNotification(t)}),this._renderErrorView()},_renderErrorView:function(){this.errorView=this._renderChildView("_notificationErrorView",i,this.$notificationErrorView,this.options)},_addNewNotification:function(e){var n=e.get("userData"),r;try{r=JSON.parse(n)}catch(i){}var s=r&&r.notificationHeading||"",o=e.get("description"),u=this.notificationSubContainerMap[o],a="",f,l,c=!0;try{r=JSON.parse(n)}catch(i){}r&&(a=r.siteCatalystName||"",r.showDownloadAll===!1&&(c=!1));if(!u){var h=_.extend({title:s,category:o,siteCatalystName:a,showDownloadAll:c,collection:this.notificationCollection},this.options);delete h.el,u=new t.NotificationSubcontainerView(h),this.addChildView(u),this.notificationSubContainerMap[o]=u,this.$notificationContainer.append(u.render().el)}f=u.createNotificationView(e),this.$notificationContainer.get(0).scrollHeight>this.$notificationContainer.get(0).clientHeight&&!this.hasBeenAdjustedOnScrollAdd&&(_.each(u.getChildViews(),function(e){e.truncateFileNameTextToFit()}),this.hasBeenAdjustedOnScrollAdd=!0),l=$(f.el).offset().top+this.$notificationContainer.scrollTop(),this.$notificationContainer.animate({scrollTop:l},200)},_addEventListeners:function(){this.listenTo(this.notificationCollection,"add",this._onNotificationAdded),this.listenTo(this.notificationCollection,"remove",this._onNotificationRemoved),this.listenTo(this.options.notificationContainerUiModel,"change:show_remove_history",this.render)},_onNotificationAdded:function(e){this._addNewNotification(e)},_onNotificationRemoved:function(e){var t=e.get("description"),n=this.notificationSubContainerMap[t],r=this.notificationCollection.filter(function(e){return e.get("description")===t});r.length===0&&(n.close(),this.notificationSubContainerMap[t]=null)},_removeIdleNotifications:function(){this.options.appApi.rnaApi.done(_.bind(function(e){this.notificationCollection.each(function(t){t.get("state")!==s.NOTIFICATION_STATES.NOT_STARTED&&t.get("state")!==s.NOTIFICATION_STATES.IN_PROGRESS&&e.notificationAPI.removeNotification(t.get("notificationID"))})},this))},_removeAllNotifications:function(){this.options.appApi.rnaApi.done(_.bind(function(e){this.notificationCollection.each(function(t){e.notificationAPI.removeNotification(t.get("notificationID"))})},this))},_onRemoveHistoryClick:function(){this._removeIdleNotifications()},_onRemoveHistoryKeyDown:function(e){if(e.which===13||e.which===32)this._consumeEvent(e),$(e.target).click()}})}),define("app/dev/templates/file-selection-dlg-template",[],function(){return''}),define("app/dev/templates/files-selection-dlg-home-views-template",[],function(){return'
'}),define("app/dev/views/view-events",["app/ac-app"],function(e){e.ViewEvents={ACCOUNT_MENU_ITEM_CLICK:"app:account-menu-item-click",ACCOUNT_MENU_BTN_CLICK:"app:account-menu-button-click",MANAGE_SUB_CLICK:"app:manage-sub-click",SIGN_OUT_CLICK:"app:sign-out-click",HELP_MENU_BTN_CLICK:"app:help-menu-button-click",ABOUT_CLICK:"app:about-click",SUPPORT_CLICK:"app:support-click",ASK_US_CLICK:"app:ask-us-click",TOOLBAR_ITEM_CLICK:"app:toolbar-item-click",STATUS_MENU_CLOSED:"app:status-menu-closed",ACROBAT_SELECT_FILTER:"app:acrobat-select-filter",ACROBAT_OPEN:"app:acrobat-open",ACROBAT_CLOSE:"app:acrobat-close",FILE_SELECTION_DLG_SELECTOR_CLICK:"app:file-selection-dlg-selector-click",FILE_SELECTION_DLG_SELECTION_CHANGE:"app:file-selection-dlg-selection-change",FILE_SELECTION_DLG_SELECTION_COMMIT:"app:file-selection-dlg-selection-commit",FILE_SAVE_AS_DLG_FILENAME_CHANGE:"app:file-save-as-dlg-filename-change",FILE_SAVE_AS_DLG_CANSAVE_CHANGE:"app:file-save-as-dlg-cansave-change",SETTINGS_DLG_SELECTOR_CLICK:"app:settings-dlg-selector-click"}}),define("app/dev/views/file-selection-dlg-selector-view",["core/ac-core","app/ac-app","core/utils/util","core/views/left-rail-view","app/views/view-events"],function(e,t,n){return t.FileSelectionDlgSelectorView=e.LeftRailView.extend({events:function(){return _.extend({},e.LeftRailView.prototype.events,{click:"_onClick"})},initialize:function(){e.LeftRailView.prototype.initialize.call(this)},render:function(){e.LeftRailView.prototype.render.call(this)},_getSelectorClickEvent:function(){return t.ViewEvents.FILE_SELECTION_DLG_SELECTOR_CLICK},_getSelectorDeleteEvent:function(){return undefined},_getSiteCatalystContext:function(){return undefined},_getSelectorViewEvent:function(){return t.ViewEvents.FILE_SELECTION_DLG_SELECTOR_CLICK},_enableEditing:function(){return!1},_onClick:function(e){var t=this.options,r=t.appApi,i;e.target===this.$el.get(0)&&(i=r.pluginsApi.callPluginMethod(t.pluginsUiModel.get("selected_plugin_id"),"hasCollectionItemCheckbox",undefined,!n.isCEF(),!0),i||r.selectionApi.clearSelection())}}),t.FileSelectionDlgSelectorView}),define("app/dev/templates/file-selection-dlg-selector-template",[],function(){return'
<%= label %>
'}),define("app/dev/views/file-selection-dlg-old-selector-view",["core/ac-core","app/ac-app","app/templates/file-selection-dlg-selector-template","core/views/plugins-selector-view","app/views/view-events"],function(e,t,n){t.FileSelectionDlgOldSelectorView=e.PluginsSelectorView.extend({initialize:function(){e.PluginsSelectorView.prototype.initialize.call(this)},_getSelectorTemplate:function(){return n},_getSelectorViewEvent:function(){return t.ViewEvents.FILE_SELECTION_DLG_SELECTOR_CLICK}})}),define("app/dev/templates/file-selection-dlg-content-template",[],function(){return'
'}),define("app/dev/views/file-selection-dlg-content-view",["core/ac-core","app/ac-app","app/templates/file-selection-dlg-content-template","core/views/plugins-content-view"],function(e,t,n){t.FileSelectionDlgContentView=e.PluginsContentView.extend({_getContentTemplate:function(){return n}})}),define("app/dev/views/file-selection-dlg-home-views-view",["core/ac-core","app/ac-app","app/templates/files-selection-dlg-home-views-template","core/utils/file-types","core/utils/sc-analytics","core/utils/util","core/views/view","app/views/file-selection-dlg-selector-view","app/views/file-selection-dlg-old-selector-view","app/views/file-selection-dlg-content-view"],function(e,t,n,r,i,s){var o={},u={},a=!1;t.FileSelectionDlgHomeViewsView=e.View.extend({initialize:function(){e.View.prototype.initialize.call(this),this._addUiModelEventListeners()},render:function(){e.View.prototype.render.call(this);var t=this.$el;t.children().length===0&&(t.html(_.template(n)({viewId:this.options.viewId})),this._initWrappers()),this._renderChildViews()},selectHomeView:function(e,n){var r;return e||(e=this.options,n?(r=e.appApi.pluginsApi.getDefaultPluginId("file_selection_dlg"),this._logSiteCatalystEvent([i.INITIAL_VIEW,e.appApi.pluginsApi.callPluginMethod(r,"getSiteCatalystName",undefined,i.UNKNOWN,!0)])):r=e.fileSelectionDlgHomeViewsUiModel.getSelectedId(),e=_.extend({},e,{pluginId:r})),n=n||{},n.scContext=this._getFullScContext(),s.isCEF()&&this.options.appApi.saveAsApi.isRunningInFileSaveAs()&&this._addHomeViewSaveAsListeners(),t.opFactory.create("SelectingFileSelectionDlgHomeViewOp",e||this.options).run(n).then(_.bind(function(){this._addHomeViewSelectionListeners()},this))},releaseHomeViews:function(){var e=this.options.appApi.pluginsApi;return o={},a=!1,this.options.fileSelectionDlgHomeViewsUiModel.get("plugins").each(function(t){var n=t.get("plugin_api");n&&e.callPluginApiMethod(n,"releasePlugin")}),this},clearSelection:function(e){var t=this.options.appApi.pluginsApi,n,r,i,s,o;return n=this.options.fileSelectionDlgHomeViewsUiModel.get("plugins"),e&&(r=e.except,s=n.get(r),s&&(o=s.cid),i=e.silent),n.each(function(e){var n=e.get("plugin_api");if(e.cid===o)return!0;if(n){var r=t.callPluginApiMethod(n,"getSelectionUiModel");r&&r.clearSelection(i)}}),this},getSelection:function(){var e=this.options,t=e.appApi.pluginsApi,n=[],i=[],s={},o,u,a,f,l;return e.fileSelectionDlgHomeViewsUiModel.get("plugins").each(function(e){a=e.get("plugin_api"),a&&(f=t.callPluginApiMethod(a,"getSelectionUiModel"),f&&(_.each(f.get("selected_local_files"),function(e){_.isArray(e)?i.push(e[0]):r.isFolder(e)||n.push(e)}),_.each(f.get("selected_item_models"),function(e){e.isFile()&&(u=e.id,s[u]=e.attributes)}),f.isSelectionComplete()&&(o=!0),f.getNumSelectedFolders()>0&&(l=!0)))}),{localFiles:n,localFileInputs:i,uploadedFileAttrs:s,isSelectionComplete:o,isFolderInSelection:l}},getSaveAsFilename:function(){return this.options.appApi.saveAsApi.getFilename()},stopListening:function(t,n,r){e.View.prototype.stopListening.call(this,t,n,r),o={},a=!1},_initWrappers:function(){this.$selector=this.$(".home-views-selector"),this.$content=this.$(".home-views-content")},_renderChildViews:function(){var e=_.extend({},this.options,{pluginsUiModel:this.options.fileSelectionDlgHomeViewsUiModel});this._renderChildView("_contentView",t.FileSelectionDlgContentView,this.$content,e),this._renderChildView("_selectorView",t.FileSelectionDlgSelectorView,this.$selector,e)},_addUiModelEventListeners:function(){this.listenTo(this.options.fileSelectionDlgHomeViewsUiModel,"change:selected_plugin_id",this._onSelectedPluginIdChange)},_addHomeViewSelectionListeners:function(){var e=this.options,t=e.appApi.pluginsApi,n,r,i;e.fileSelectionDlgHomeViewsUiModel.get("plugins").each(_.bind(function(e){n=e.get("id"),o[n]||(r=e.get("plugin_api"),r&&(i=t.callPluginApiMethod(r,"getSelectionUiModel"),i&&(u[n]=i,this.listenTo(i,"change:selected_local_files",this._onHomeViewSelectedLocalFilesChange),this.listenTo(i,"change:selected_item_models",this._onHomeViewSelectedItemModelsChange),this.listenTo(i,"change:commit_selection",this._onHomeViewCommitSelectionChange),o[n]=!0)))},this))},_addHomeViewSaveAsListeners:function(){a||(this.listenTo(this.options.saveAsUiModel,"change:filename",this._onHomeViewSaveAsFilenameChange),this.listenTo(this.options.saveAsUiModel,"change:canSave",this._onHomeViewSaveAsCanSaveChange),a=!0)},_onSelectedPluginIdChange:function(){this.render()},_getPluginId:function(e){var t;return _.each(u,function(n,r){n.cid===e.cid&&(t=r)}),t},_clearOthersIfSingle:function(e){var t=this._getPluginId(e);e.get("multiple_selection")||this.clearSelection({except:t,silent:!0})},_onHomeViewSelectedLocalFilesChange:function(e){this._clearOthersIfSingle(e),this._triggerViewEvent(t.ViewEvents.FILE_SELECTION_DLG_SELECTION_CHANGE)},_onHomeViewSelectedItemModelsChange:function(e){this._clearOthersIfSingle(e),this._triggerViewEvent(t.ViewEvents.FILE_SELECTION_DLG_SELECTION_CHANGE)},_onHomeViewCommitSelectionChange:function(e,n){n&&this._triggerViewEvent(t.ViewEvents.FILE_SELECTION_DLG_SELECTION_COMMIT)},_onHomeViewSaveAsFilenameChange:function(){this._triggerViewEvent(t.ViewEvents.FILE_SAVE_AS_DLG_FILENAME_CHANGE)},_onHomeViewSaveAsCanSaveChange:function(){this._triggerViewEvent(t.ViewEvents.FILE_SAVE_AS_DLG_CANSAVE_CHANGE)}})}),define("app/dev/views/file-selection-dlg-view",["core/ac-core","app/ac-app","core/utils/util","app/templates/file-selection-dlg-template","i18n!core/nls/ui-strings","core/utils/css-util","core/utils/view-util","core/utils/string-util","core/utils/sc-analytics","core/views/dialog-view","app/views/file-selection-dlg-home-views-view","app/views/modal-mask-view"],function(e,t,n,r,i,s,o,u,a){t.FileSelectionDlgView=e.DialogView.extend({events:function(){return _.extend({},e.DialogView.prototype.events,{"click .file-selection-dlg-continue-btn":"_onContinueClick","click .file-selection-dlg-cancel-btn":"_onCancelClick"})},initialize:function(){e.DialogView.prototype.initialize.call(this),this._setParentScContext(this.options.scContext)},render:function(){return e.DialogView.prototype.render.call(this,!1),this.$el.empty().html(_.template(r)({cancel:i.CANCEL,ariaCancel:this._getariaCancel(),continueLabel:this._getContinueLabel(),ariaContinueLabel:this._getAriaContinueLabel(),headerLabel:this._getHeaderLabel()})),this._initWrappers(),(!n.isCEF()||!this.options.runningInFileSelection)&&this._center({horizontalOnly:!0}),n.isWindows()&&o.swapChildElements(this.$dlgControlBtns),this.$dlg.addClass("shown unselectable"),this.$cancelBtn.focus(),this._renderChildViews(),this._enableContinueBtn(),this},open:function(r){var i,s=this.options,o=s.appApi,u=o.pluginsApi,a=o.saveAsApi,f,l,c,h,p=a.isRunningInFileSaveAs();return s.nonDefaultRecent&&!p&&u.setDefaultPluginId("file_selection_dlg","my_computer_select"),this._pluginOptions=r,f=t.opFactory.create("LoadingFileSelectionDlgHomeViewsOp",s),o.displayApi.applyUIThemeStyles(this.$el).then(_.bind(function(){return f.run(!1).then(_.bind(function(){return n.isCEF()&&(p&&this._settingDefaultForSaveAsDlg(),o.connectorsApi.addConnectorsChangeCallback(this._onConnectorsChange),o.connectorsApi.addConnectorsUiHelpersChangeCallback(this._onConnectorsChange),o.sessionApi.addSignedInChangeCallback(this._enableContinueBtn)),u.callPluginMethodForEach(s.fileSelectionDlgHomeViewsUiModel.getAllIds(),"setPluginOptions",r,undefined,!0),u.callSelectorMethodForEach(s.fileSelectionDlgHomeViewsUiModel.getAllIds(),"setPluginOptions",r,undefined,!0),i=e.DialogView.prototype.open.call(this),this._repositionSpinner(),(!p||p&&this._setDefaultForSaveAs)&&this._homeViewsView.clearSelection().selectHomeView(undefined,r),i},this))},this))},close:function(t,r){var i=this.$dlg,o,u=r&&r.noAnimation||n.isCEF(),a=this.options,f=a.appApi;delete this._pluginOptions,delete this._setDefaultForSaveAs,o=_.bind(function(){n.isCEF()&&(f.connectorsApi.removeConnectorsChangeCallback(this._onConnectorsChange),f.connectorsApi.removeConnectorsUiHelpersChangeCallback(this._onConnectorsChange),f.sessionApi.removeSignedInChangeCallback(this._enableContinueBtn)),s.removeTransitionEndCallbacks(i),a.selectionUiModel.clearSelection(),this._restoreSpinnerPosition(),this._homeViewsView.releaseHomeViews(),a.fileSelectionDlgHomeViewsUiModel.set("plugins",e.uiCollectionFactory.create("PluginsUiCollection")),e.DialogView.prototype.close.call(this,t,r)},this);if(!i)return;i.removeClass("shown"),u?o():s.addTransitionEndCallback(i,"top",o)},_onViewEvent:function(e,r){var i=t.ViewEvents,s=this.options.appApi.saveAsApi;if(e===i.FILE_SELECTION_DLG_SELECTION_CHANGE){this._enableContinueBtn();return}if(e===i.FILE_SELECTION_DLG_SELECTION_COMMIT){this._onContinueClick();return}if(e===i.FILE_SELECTION_DLG_SELECTOR_CLICK){n.isCEF()&&(r&&r.pluginId&&(o.enableInput(this.$continueBtn,!1),this.$continueBtn.val(this._getContinueLabel(r.pluginId))),s.isRunningInFileSaveAs()&&s.clearNonSharedSaveAsAttributes()),this._homeViewsView.clearSelection().selectHomeView(r,this._pluginOptions).always(_.bind(function(){n.isCEF()&&this._enableContinueBtn()},this));return}if(n.isCEF()){if(e===i.FILE_SAVE_AS_DLG_FILENAME_CHANGE){this._enableContinueBtn();return}if(e===i.FILE_SAVE_AS_DLG_CANSAVE_CHANGE){this._enableContinueBtn();return}}this.trigger(e,r)},_initWrappers:function(){e.DialogView.prototype._initWrappers.call(this),this.$pageHeader=$(".page-header"),this.$spinner=$(".spinner"),n.isCEF()&&(this.$modalMask=$("#modal-mask")),this.$dlg=this.$(".generic-dialog"),this.$homeViews=this.$(".home-views"),this.$dlgControlBtns=this.$(".file-selection-dlg-control-buttons"),this.$continueBtn=this.$(".file-selection-dlg-continue-btn"),this.$cancelBtn=this.$(".file-selection-dlg-cancel-btn")},_getContinueLabel:function(e){var t=this.options,r=t.appApi.pluginsApi,s=e||r.getSelectedPluginId("file_selection_dlg")||r.getDefaultPluginId("file_selection_dlg");return n.isCEF()&&s==="my_computer_select"?t.appApi.saveAsApi.isRunningInFileSaveAs()?i.CHOOSE_DIFFERENT_FOLDER:i.BROWSE_FOLDER:t.addSelectedButtonLabel||i.CONTINUE},_getAriaContinueLabel:function(e){var t=this.options,r=t.appApi.pluginsApi,s=e||r.getSelectedPluginId("file_selection_dlg")||r.getDefaultPluginId("file_selection_dlg");return n.isCEF()&&s==="my_computer_select"?t.appApi.saveAsApi.isRunningInFileSaveAs()?i.CHOOSE_DIFFERENT_FOLDER+" "+i.BUTTON:i.BROWSE_FOLDER+" "+i.BUTTON:t.addSelectedButtonLabel||i.CONTINUE},_getariaCancel:function(){return i.CANCEL+" "+i.BUTTON},_getHeaderLabel:function(){var e,t=this._pluginOptions;return e=t&&t.singleFileSelection===!0?i.SELECT_FILE:i.SELECT_FILES,this.options.fileSelectionDlgHeaderLabel||e},_enableContinueBtn:function(){var e=this._getSelection(),t,r,i,s,u=this.options,a=u.appApi,f=a.pluginsApi,l=a.saveAsApi,c=!0,h,p=a.sessionApi.isSignedIn();n.isCEF()&&(this.$continueBtn.val(this._getContinueLabel()),this.$continueBtn.attr("aria-label",this._getAriaContinueLabel())),i=f.getSelectedPluginId("file_selection_dlg")||f.getDefaultPluginId("file_selection_dlg"),s=a.connectorsApi.isConnectorPlugin(i)&&a.connectorsApi.isDesktopConnector(a.connectorsApi.getConnectorPluginName(i)),t=e.localFiles.length+e.localFileInputs.length+_.keys(e.uploadedFileAttrs).length,n.isCEF()&&l.isRunningInFileSaveAs()?(r=this._getSaveAsFilename(),i==="my_computer_select"?o.enableInput(this.$continueBtn,!0):(c=l.getCanSave()&&e.isFolderInSelection!==!0&&r!==undefined&&r.length>0&&(s||p),!s&&p?a.rnaApi.done(_.bind(function(e){a.sessionApi.ensureSignedIn().done(_.bind(function(){h=e.rnaServicesAPI.isEnterpriseUser()&&(!e.rnaServicesAPI.isPDFServicesEnabled()||!e.rnaServicesAPI.isEncryptionKeyValid()),h&&(c=!1),o.enableInput(this.$continueBtn,c)},this))},this)):o.enableInput(this.$continueBtn,c)),e.isSelectionComplete&&r!==undefined&&this._onContinueClick()):(n.isCEF()&&i==="my_computer_select"?o.enableInput(this.$continueBtn,!0):n.isCEF()&&i==="my_recent_files_select"?o.enableInput(this.$continueBtn,t>0):o.enableInput(this.$continueBtn,t>0&&(s||this.options.appApi.sessionApi.isSignedIn())),e.isSelectionComplete&&this._onContinueClick())},_getSelection:function(){var e=this._homeViewsView;return e?e.getSelection():{localFiles:[],localFileInputs:[],uploadedFileAttrs:{},isSelectionComplete:!1,isFolderInSelection:!1}},_getSaveAsFilename:function(){var e=this._homeViewsView;return e?e.getSaveAsFilename():undefined},_sanitizeFileNameForExtension:function(){var e=this._getSaveAsFilename(),t=this.options.appApi.saveAsApi,r,i,s,o,a;_.isUndefined(e)||(a=u.getNormalizedString(e,"NFC"),_.isUndefined(a)||(e=a),r=t.getChosenFileFilter(),i=r.fileFilterExtensions,s=n.getExtension(e),i.length>=1&&(_.isUndefined(s)||(o=_.find(i,function(e){return e.toLowerCase()===s})),_.isUndefined(o)&&(e+=".",e+=i[0])),t.setFilename(e))},_releaseFileInputCallback:function(e){var t=$("#"+e);t.remove()},_renderChildViews:function(){this._renderHomeViewsView(),n.isCEF()&&this._renderModalMaskView()},_renderHomeViewsView:function(){this._renderChildView("_homeViewsView",t.FileSelectionDlgHomeViewsView,this.$homeViews,{childViewId:"_homeViewsView"})},_renderModalMaskView:function(){this.options.modalMaskUiModel.set({modal_transparent:!0}),this._renderChildView("_modalMaskView",t.ModalMaskView,this.$modalMask,{childViewId:"_modalMaskView"})},_repositionSpinner:function(){this.options.appApi.displayApi.setSpinnerOptions({refElem:this.$(".home-views-content")})},_restoreSpinnerPosition:function(){this.options.appApi.displayApi.clearSpinnerOptions()},_onKeyDown:function(t){var r=$(t.target);return n.isCEF()&&t.which===9?!1:t.which===13&&o.isInputEnabled(this.$continueBtn)&&t.target!==this.$cancelBtn.get(0)?(this._consumeEvent(t),this._onContinueClick(),!0):n.isCEF()&&t.which===8&&(!r.is("input")||r.hasClass("control-button"))&&!r.is("textarea")&&this.options.appApi.selectionApi.isRunningInFileSelection()?(this._consumeEvent(t),!0):e.DialogView.prototype._onKeyDown.call(this,t)},_onContinueClick:function(){var e=this.options,t=e.appApi,r=t.pluginsApi,i=[],s,o=[],u=r.getSelectedPluginId("file_selection_dlg")||r.getDefaultPluginId("file_selection_dlg");if(!n.isCEF())return this._closeOnContinue();if(u==="my_computer_select")return this._logSiteCatalystEvent([a.MY_COMPUTER,a.BROWSE,a.CLICKED]),t.rnaApi.done(function(e){e.rnaFileAPI.openPlatformDialog()});u==="my_recent_files_select"?(s=t.selectionApi.getSelectedItemModels(),t.rnaApi.done(function(e){e.whitelistRecentFile(s)})):e.fileSelectionDlgHomeViewsUiModel.get("plugins").each(function(t){if(t.id===u){var n=t.get("plugin_api");n&&(i=e.appApi.pluginsApi.callPluginApiMethod(n,"getFolderAncestorIds"))}}),e.readerContextModel.done(_.bind(function(e){var n=e.get("rna"),r=0,a,f=0;this.fsData=n.get("viewData").get("fileSelectData");if(u==="root-select"||u==="ccloud-select")f=1;_.each(s,function(e){o[r++]=e.get("index")}),a=[i,f,o],this.fsData.invoke("setFileAncestors",a).then(_.bind(function(){return t.saveAsApi.isRunningInFileSaveAs()?(t.saveAsApi.setChosenFileFilterAsPerFilename(),this._sanitizeFileNameForExtension(),this._checkForIllegalName().then(_.bind(function(){return this._checkForExistingFileAndClose()},this))):this._closeOnContinue()},this))},this))},_checkForIllegalName:function(){var t=this.options,n,r,i=t.appApi.pluginsApi,s=t.appApi.connectorsApi,o=t.appApi.saveAsApi,u;return r=i.getSelectedPluginId("file_selection_dlg"),s.isConnectorPlugin(r)&&s.isDesktopConnector(s.getConnectorPluginName(r))?(u=this.options.appApi.pluginsApi.callPluginMethod(r,"isFilenameValid",this._getSaveAsFilename(),this._getResolvedPromise(),!0),u.then(undefined,function(e){o.setError(e)})):(n=e.opFactory.create("ValidatingNameOp",_.extend(t,{name:this._getSaveAsFilename()})),n.run().then(undefined,function(e){o.setError(e)}))},_checkForExistingFileAndClose:function(){var e=this._getSelection(),t=this._getSaveAsFilename(),n=this.options,r,i,s,o;return _.keys(e.uploadedFileAttrs).length===1&&_.each(e.uploadedFileAttrs,function(e,n){if(t===e.name){i=n,o=e.name;return}}),i===undefined&&(r=n.appApi.pluginsApi.callPluginMethod(n.appApi.pluginsApi.getSelectedPluginId("file_selection_dlg"),"doesFileExists",t,undefined,!0),r&&(i=r.get("id"),o=r.get("name"),s=r)),i||s?this._showReplaceFileDialog().then(_.bind(function(){return i&&n.appApi.saveAsApi.setReplaceFileId(i),s&&n.appApi.saveAsApi.setReplaceFileObj(s),n.appApi.saveAsApi.setFilename(o),this._closeOnContinue()},this)):this._closeOnContinue()},_showReplaceFileDialog:function(){var e={},t;return n.isCEF()&&(e.okButtonClass="replace-file-aria-label"),t=this.options.appApi.dialogApi.displayTextAlert(this.options.appApi.dialogApi.SEVERITY_WARNING,i.REPLACE_EXISTING_FILE_TITLE,i.REPLACE_EXISTING_FILE_MSG,i.YES,i.NO,e),n.isCEF()&&$(".replace-file-aria-label").attr("aria-label",i.REPLACE_EXISTING_FILE_ARIA_LABEL),t},_closeOnContinue:function(){var e=this._getSelection(),t=e.localFiles.length,r=_.keys(e.uploadedFileAttrs).length,i=t+r,s=[];this._logSiteCatalystEvent(a.CONTINUE),n.isCEF()||(t>0?r>0?(s.push(a.ACOM_AND_MY_COMPUTER),s.push(a.SUCCESS),s.push(a.getCountCode(i))):(s.push(a.MY_COMPUTER_ONLY),s.push(a.SUCCESS),s.push(a.getCountCode(t))):(s.push(a.ACOM_ONLY),s.push(a.SUCCESS),s.push(a.getCountCode(r))),this._logSiteCatalystEvent(s)),this.close(!0,{resolveArgs:_.extend(e,{releaseFileInputCallback:this._releaseFileInputCallback})})},_onCancelClick:function(){this.close(!1)},_settingDefaultForSaveAsDlg:function(){var e,t,n,r=this.options.appApi,i=r.saveAsApi,s=r.pluginsApi;e=i.getSourceKey(),t=i.getAccountId(),!_.isUndefined(e)&&e!==""&&e!=="local"&&(!_.isUndefined(t)&&t!==""||e==="root"||e==="ccloud")?(this._setDefaultForSaveAs=!1,n=r.connectorsApi.getConnectorPluginId(e,t,!0),s.setDefaultPluginId("file_selection_dlg",n),s.getDefaultPluginId("file_selection_dlg")===n?(this._setDefaultForSaveAs=!0,s.getPluginsUiModel(n).setSelectedId(n)):s.setDefaultPluginIdAsUndefined("file_selection_dlg")):(s.setDefaultPluginId("file_selection_dlg","my_computer_select"),this._setDefaultForSaveAs=!0)},_onConnectorsChange:function(){e.opFactory.create("InstantiatingConnectorsOp",this.options).run({pluginsUiModel:this.options.fileSelectionDlgHomeViewsUiModel,inFileSelectionDlg:!0}).then(_.bind(function(){this.options.appApi.saveAsApi.isRunningInFileSaveAs()&&!this._setDefaultForSaveAs&&(this._settingDefaultForSaveAsDlg(),this._setDefaultForSaveAs&&this._homeViewsView.clearSelection().selectHomeView(undefined,this._pluginOptions)),this._renderHomeViewsView()},this))}})}),define("app/dev/templates/whats-new-dlg-template",[],function(){return'
'}),define("app/dev/views/whats-new-dlg-view",["core/ac-core","app/ac-app","core/utils/util","app/templates/whats-new-dlg-template","i18n!core/nls/ui-strings","core/views/dialog-view"],function(e,t,n,r,i){t.WhatsNewDlgView=e.DialogView.extend({initialize:function(){e.DialogView.prototype.initialize.call(this),this._setParentScContext(this.options.scContext),this._template=_.template(r)({CLOSE:i.CLOSE})},render:function(){return e.DialogView.prototype.render.call(this,!1),this._appendToDialog(this._template),this._setCss(),this.initWrappers(),this.getWhatsNewPageUrl(),this.loadWhatsNewPageUrl(),this._addUiEventListeners(),this},initWrappers:function(){this.$WhatsNewIframe=this.$(".whats-new-iframe"),this.$WhatsNewCloseBtn=this.$(".whats-new-page-close-btn")},_addUiEventListeners:function(){this.$WhatsNewCloseBtn.on("click",this._onCalCloseClick)},open:function(t){var n,r=this.options.appApi;return r.displayApi.applyUIThemeStyles(this.$el).then(_.bind(function(){return n=e.DialogView.prototype.open.call(this),r.displayApi.showSpinner(!1),n},this))},_setCss:function(){this.$dlg.css("width","100%"),this.$dlg.css("height","100%"),this.$dlg.css("border","0px"),this.$dlg.css("margin","0px"),this.$dlg.css("padding","0px"),this.$dlg.css("outline","none"),this.$dlg.css("position","absolute"),this.$dlg.css("text-align","left"),this.$dlg.css("text-shadow","none"),this.$dlg.css("top","0px"),this.$dlg.css("left","0px"),this.$dlg.css("border-radius","0px"),this.$titleBar.hide()},_onCalCloseClick:function(){this.options.appApi.rnaApi.done(_.bind(function(e){e.invokeMethod({methodName:"CloseWhatsNewDialog",methodArgs:""})},this))},loadWhatsNewPageUrl:function(){var e=this.newFeaturesUrl+"?timestamp="+Date.now();this.$WhatsNewIframe.attr("src",e)},getWhatsNewPageUrl:function(){this.queryParams=this.options.appApi.routerApi.parseQueryParams(window.location.href.slice(window.location.href.indexOf("?"))),this.newFeaturesUrl=this.queryParams.url,console.log(" url = "+this.newFeaturesUrl)}})}),define("app/dev/views/acrobat-command-page-view",["app/ac-app","app/views/content-page-view"],function(e){e.AcrobatCommandPageView=e.ContentPageView.extend({_initWrappers:function(){e.ContentPageView.prototype._initWrappers.call(this),this.$el.css("overflow","hidden")},_renderPageHeaderView:function(){},_renderAcrobatFooterView:function(){},_renderModalMaskView:function(){}})}),define("app/dev/views/view-mgr",["core/ac-core","app/ac-app","core/utils/util","core/views/view","app/views/content-page-view","app/views/rhp-content-page-view","app/views/notification-content-page-view","app/views/file-selection-dlg-view","app/views/whats-new-dlg-view","app/views/acrobat-command-page-view"],function(e,t,n){var r;t.ViewMgr=e.View.extend({getContentPageView:function(e){var i,s=".content-page";if(n.isCEF())if(e.runningInRHP)s=".rhp-content-page";else if(e.runningInNotification)s=".notification-content-page";else if(e.runningInFileSelection||e.runningInFileSaveAs||e.runningInWhatsNewView)s=".dialog-container";return r||(i=_.extend({},e,{el:s}),n.isCEF()?e.runningInRHP?r=new t.RHPContentPageView(i):e.runningInNotification?r=new t.NotificationContentPageView(i):e.runningInFileSelection||e.runningInFileSaveAs?r=new t.FileSelectionDlgView(i):e.runningInWhatsNewView?r=new t.WhatsNewDlgView(i):e.runningInCommand?r=new t.AcrobatCommandPageView(i):r=new t.ContentPageView(i):r=new t.ContentPageView(i),this.addChildView(r),e.rootView=r),r},showContentPageView:function(e){var t;t=this.getContentPageView(e),t.$el.show(),t.render()},unsetContentPageView:function(){r&&(this.removeChildView(r),r=undefined)},isContentPageViewUnset:function(){return r===undefined}})}),define("app/dev/ops/account-menu/loading-account-menu-op",["core/ac-core","app/ac-app","core/utils/util","core/ops/op"],function(e,t,n){return t.LoadingAccountMenuOp=e.Op.extend({run:function(){var t=this.options,r=t.appApi.pluginsApi,i;return n.isCEF()&&(i={readerContextModel:t.readerContextModel}),e.opFactory.create("LoadingPluginsOp",_.extend({pluginsConfig:r.getPluginTypeConfig("account_menu"),pluginsUiModel:t.accountMenuPluginsUiModel,pluginContext:i},_.pick(t,"appApi","pluginId","force"))).run()}}),t.LoadingAccountMenuOp}),define("app/dev/ops/account-menu/selecting-account-menu-item-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){t.SelectingAccountMenuItemOp=e.Op.extend({run:function(){var t=this.options;return t.pageHeaderUiModel.set("show_account_menu",!1),e.opFactory.create("SelectingPluginOp",t).run()}})}),define("app/dev/ops/acrobat/closing-in-acrobat-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){t.ClosingInAcrobatOp=e.Op.extend({run:function(){return document.location="acrobatskybox://closewindow",this._getResolvedPromise()}})}),define("app/dev/ops/acrobat/opening-in-acrobat-op",["core/ac-core","app/ac-app","i18n!core/nls/ui-strings","core/ops/op"],function(e,t,n){t.OpeningInAcrobatOp=e.Op.extend({run:function(){var e=this.options,t=e.acrobatUiModel,r=$.Deferred(),i,s,o,u,a,f;return u=e.ids,a=u.length,a>t.get("file_open_max_count")?(e.errorUiModel.enqueueMiscError(n.MISC_ERROR_ACROBAT_FILE_OPEN_MAX_TITLE,n.MISC_ERROR_ACROBAT_FILE_OPEN_MAX_MSG),r.reject().promise()):(e.selectionUiModel.clearSelection(),i=t.isFolderSelectionMode(),a>1?(f=[],_.each(u,function(e){f.push(encodeURIComponent(e))}),s=i?"openFolders":"openDocuments",o="acrobatskybox://"+s+"/?assetIDs="+f.join(";")):(s=i?"openFolder":"openDocument",o="acrobatskybox://"+s+"/?assetID="+encodeURIComponent(u[0])),document.location=o,r.resolve().promise())}})}),define("app/dev/ops/acrobat/selecting-acrobat-filter-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){t.SelectingAcrobatFilterOp=e.Op.extend({run:function(){var e=this.options,t=e.appApi.acrobatApi,n;return n=e.filterIndex,n===undefined?n=t.getSelectedFilterIndex():t.setSelectedFilterIndex(n),this._getResolvedPromise()}})}),define("app/dev/ops/app/rna-starting-app-op",["core/ac-core","app/ac-app","core/utils/date-util","core/utils/view-util","core/ops/op"],function(e,t,n,r){return t.RNAStartingAppOp=e.Op.extend({run:function(){var r=this.options,i,s,o,u,a,f,l,c,h,p,d=this._getResolvedPromise(),v,m,g;return i=e.opFactory,s=t.opFactory,s.create("OverridingJQueryAjaxOp",r).run(),s.create("LoadingCustomCssOp",r).run(),s.create("ListeningForAjaxEventsOp",r).run(),s.create("ListeningForServerErrorsOp",r).run(),o=s.create("RegisteringAppApisOp",r),u=s.create("InitializingAppRoutesOp",r),f=s.create("HandlingUncaughtExceptionsOp",r),a=s.create("ListeningForDownloadErrorsOp",r),h=s.create("StartingHistoryOp",r),l=s.create("LoadingPluginConfigsOp",r),p=s.create("RegisteringPluginsUiModels",r),c=s.create("RNARunningAppOp",r),v=s.create("InitializingRNAOp",r),m=s.create("ConfiguringRNAOp",r),g=i.create("GettingSiteCatalystBaseFileOp",r),n.logElapsedTime("before loading app-apis"),v.run().then(function(){return o.run(),r.appApi.displayApi.applyUIThemeStyleFramework(),u.run(),p.run(),f.run(),a.run(),n.logElapsedTime(" after initializingRNAOp"),$.when(l.run()).always(function(){return n.logElapsedTime("after RNA + plugin configs"),m.run().then(function(){return h.run(),e.isJasmine()?d:c.run()})})})}}),t.RNAStartingAppOp}),define("app/dev/ops/app/rna-running-app-op",["core/ac-core","files/ac-files","app/ac-app","core/ops/op"],function(e,t,n){n.RNARunningAppOp=e.Op.extend({run:function(){var r=this.options,i,s,o,u,a,f,l,c,h,p,d,v,m,g;return i=e.opFactory,s=t.opFactory,o=n.opFactory,u=o.create("ListeningForWindowEventsOp",r),a=i.create("ListeningForKeyEventsOp",r),f=o.create("ListeningForViewEventsOp",r),l=o.create("ListeningForInactivityOp",r),c=o.create("ListeningForNetworkConnectivityOp",r),g=i.create("ListeningForFocusEventsOp",r),h=s.create("ListeningForQuotaErrorsOp",r),p=o.create("ListeningForRNAEventsOp",r),d=i.create("ListeningForActions",r),v=o.create("ListeningForSessionEventsOp",r),m=o.create("ListeningForDialogAlertEventsOp",r),$.when(u.run(),a.run(),g.run(),f.run(),l.run(),c.run(),h.run(),p.run(),d.run(),v.run(),m.run())}})}),define("app/dev/ops/app/running-app-op",["core/ac-core","files/ac-files","app/ac-app","core/ops/op"],function(e,t,n){n.RunningAppOp=e.Op.extend({run:function(){var r=this.options,i,s,o,u,a,f,l,c,h;return i=e.opFactory,s=t.opFactory,o=n.opFactory,u=o.create("ListeningForWindowEventsOp",r),a=i.create("ListeningForKeyEventsOp",r),f=i.create("ListeningForFocusEventsOp",r),l=o.create("ListeningForViewEventsOp",r),c=o.create("ListeningForInactivityOp",r),h=s.create("ListeningForQuotaErrorsOp",r),$.when(u.run(),a.run(),f.run(),l.run(),c.run(),h.run())}})}),define("app/dev/ops/app/starting-app-op",["core/ac-core","app/ac-app","core/utils/date-util","core/utils/view-util","core/ops/op"],function(e,t,n,r){return t.StartingAppOp=e.Op.extend({run:function(){var i=this.options,s,o,u,a,f,l,c,h,p,d,v,m,g,y;n.logElapsedTime("begin starting-app-op"),r.init(),s=e.opFactory,o=t.opFactory,o.create("OverridingJQueryAjaxOp",i).run(),o.create("LoadingCustomCssOp",i).run(),o.create("ListeningForAjaxEventsOp",i).run(),o.create("ListeningForServerErrorsOp",i).run(),u=o.create("LoadingTypekitOp",i),a=o.create("LoadingFrameworkVersionsOp",i),f=o.create("RegisteringAppApisOp",i),l=o.create("InitializingAppRoutesOp",i),c=o.create("RegisteringPluginsUiModels",i),h=o.create("HandlingUncaughtExceptionsOp",i),p=o.create("ListeningForDownloadErrorsOp",i),d=o.create("GettingAllBaseUrisOp",i),v=o.create("LoadingPluginConfigsOp",i),m=o.create("LoadingPluginConfigsVersionsOp",i),g=s.create("StartingSusiSessionOp",i),y=o.create("StartingAuthenticatedAppOp",i),u.run(),a.run().always(function(){return n.logElapsedTime("before loading app-apis"),f.run(),l.run(),c.run(),h.run(),p.run(),n.logElapsedTime("before base uris + plugin configs"),$.when(d.run(),v.run()).always(function(){return n.logElapsedTime("after base uris + plugin configs"),m.run().then(function(){return g.run().then(function(){return n.logElapsedTime("after starting susi"),y.run()})})})})}}),t.StartingAppOp}),define("app/dev/ops/app/starting-authenticated-app-op",["core/ac-core","app/ac-app","core/utils/date-util","core/ops/op"],function(e,t,n){return t.StartingAuthenticatedAppOp=e.Op.extend({run:function(){var r=this.options,i,s,o,u,a,f,l,c,h,p,d,v=this._getResolvedPromise();return n.logElapsedTime("begin starting-app-op"),i=t.opFactory,h=i.create("StartingHistoryOp",r),s=i.create("GettingAllUserInfoOp",r),u=i.create("LoadingToolsOp",r),a=i.create("LoadingDeepLinkPluginsOp",r),f=i.create("LoadingTemplatePluginsOp",r),l=i.create("LoadingAccountMenuOp",r),c=i.create("GettingStorageInfoOp",r),p=i.create("ShowingLoadFailuresDlgOp",r),o=i.create("RunningAppOp",r),d=i.create("RedirectingToApolloOp",r),n.logElapsedTime("initializing authenticated session"),s.run().always(function(){return d.run(),$.when.apply(undefined,[c.run(),l.run(),u.run(),a.run(),f.run()]).always(function(){return n.logElapsedTime("after loading plugins + connector info"),t.viewMgr.showContentPageView(r),h.run(),e.isJasmine()?v:(p.run(),o.run())})})}}),t.StartingAuthenticatedAppOp}),define("app/dev/ops/file-selection-dlg/loading-file-selection-dlg-home-views-op",["core/ac-core","app/ac-app","core/utils/util","core/ops/op"],function(e,t,n){t.LoadingFileSelectionDlgHomeViewsOp=e.Op.extend({run:function(t){var r=this.options,i=r.appApi.pluginsApi,s=r.fileSelectionDlgHomeViewsUiModel,o=e.opFactory,u,a;return n.isCEF()&&(a={readerContextModel:r.readerContextModel}),u=o.create("LoadingPluginsOp",_.extend({pluginsConfig:i.getPluginTypeConfig("file_selection_dlg"),pluginsUiModel:s,pluginContext:a},_.pick(r,"appApi","pluginId","force"))),u.run().then(function(){if(!t)return o.create("InstantiatingConnectorsByCohortOp",r).run({pluginsUiModel:s,inFileSelectionDlg:!0})})}})}),define("app/dev/ops/file-selection-dlg/selecting-file-selection-dlg-home-view-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){t.SelectingFileSelectionDlgHomeViewOp=e.Op.extend({run:function(t){return e.opFactory.create("SelectingPluginOp",this.options).run(t)}})}),define("app/dev/ops/file-selection-dlg/showing-file-selection-dlg-op",["core/ac-core","app/ac-app","core/utils/util","core/ops/op","app/views/file-selection-dlg-view"],function(e,t,n){t.ShowingFileSelectionDlgOp=e.Op.extend({run:function(e){var r,i=this.options;return n.isCEF()&&(i.runningInFileSelection||i.runningInFileSaveAs)?r=t.viewMgr.getContentPageView(i):r=new t.FileSelectionDlgView(i),r.open(e)}})}),define("app/dev/ops/file-selection-dlg/loading-file-selection-dlg-op",["app/ac-app","core/ac-core","core/utils/file-types","core/ops/op"],function(e,t){return e.LoadingFileSelectionDlgOp=t.Op.extend({run:function(){return this.options.readerContextModel.done(_.bind(function(e){var t=e.get("rna"),n,r,i;if(t.hasProperty("viewData")){this.fsData=t.get("viewData").get("fileSelectData"),n="home",i={dialog:{singleFileSelection:!0},plugin:{filter:{minSize:1,maxSize:1e8,mimeTypes:[],extensions:[]}}},this.fsData.hasProperty("nonDefaultRecent")&&(this.options.nonDefaultRecent=this.fsData.get("nonDefaultRecent")),this.fsData.hasProperty("showRecent")&&(i.plugin.showRecent=this.fsData.get("showRecent")),this.fsData.hasProperty("actionButtonText")&&(i.dialog.addSelectedButtonLabel=this.fsData.get("actionButtonText")),this.fsData.hasProperty("headerLabel")&&(i.dialog.fileSelectionDlgHeaderLabel=this.fsData.get("headerLabel")),this.fsData.hasProperty("fileFilterList")&&(r=this.fsData.get("fileFilterList"),r.forEach(function(e){var t=e.get("fileFilterExtensions");t.forEach(function(e){if(i.plugin.filter.extensions.indexOf(e)!==-1)return;i.plugin.filter.extensions.push(e)})})),this.fsData.hasProperty("fileMimeTypes")&&(i.plugin.filter.mimeTypes=this.fsData.get("fileMimeTypes")),this.options.appApi.saveAsApi.isRunningInFileSaveAs()?(i.dialog.singleFileSelection=!0,i.plugin.filter.minSize=undefined,i.plugin.filter.maxSize=undefined):this.fsData.hasProperty("allowMultiple")&&(i.dialog.singleFileSelection=!this.fsData.get("allowMultiple")),i.plugin.showRecent||(this.options.nonDefaultRecent=!0),this.fsData.hasProperty("disableDocumentCloud")&&this.options.tunerUiModel.set("disable_document_cloud",this.fsData.get("disableDocumentCloud")),this.fsData.hasProperty("disableWebConnectors")&&this.options.tunerUiModel.set("disable_web_connectors",this.fsData.get("disableWebConnectors")),this.fsData.hasProperty("disableLocalConnectors")&&this.options.tunerUiModel.set("disable_local_connectors",this.fsData.get("disableLocalConnectors")),this.fsData.hasProperty("initialSaveAsFilename")&&this.options.appApi.saveAsApi.setFilename(this.fsData.get("initialSaveAsFilename")),this.fsData.hasProperty("selectedToolPlugin")&&(i.plugin.selectedToolPlugin=this.fsData.get("selectedToolPlugin")),this.fsData.hasProperty("scContext")&&(i.plugin.pluginScContext=this.fsData.get("scContext"));var s=this.options.saveAsUiModel;return this.fsData.hasProperty("fileOptionsRFS")&&s.set("fileOptionsRFS",this.fsData.get("fileOptionsRFS")),this.fsData.hasProperty("fileFilterList")&&s.set("fileFilterList",this.fsData.get("fileFilterList")),this.fsData.hasProperty("defaultFileFilter")&&s.set("chosenFileFilter",this.fsData.get("defaultFileFilter")),this.fsData.hasProperty("showExportOptions")&&s.set("showExportOptions",this.fsData.get("showExportOptions")),this.fsData.hasProperty("allowSettingsButton")&&s.set("allowSettingsButton",this.fsData.get("allowSettingsButton")),this.fsData.hasProperty("allowViewResult")&&s.set("allowViewResult",this.fsData.get("allowViewResult")),this.fsData.hasProperty("isReduceFileSizeEnabled")&&s.set("reduceFileSizeEnabled",this.fsData.get("isReduceFileSizeEnabled")),this.fsData.hasProperty("isRestrictEditingEnabled")&&s.set("restrictEditingEnabled",this.fsData.get("isRestrictEditingEnabled")),this.fsData.hasProperty("isReduceFileSizeVisible")&&s.set("reduceFileSizeVisible",this.fsData.get("isReduceFileSizeVisible")),this.fsData.hasProperty("isRestrictEditingVisible")&&s.set("restrictEditingVisible",this.fsData.get("isRestrictEditingVisible")),this.fsData.hasProperty("initialSourceKey")&&s.set("sourceKey",this.fsData.get("initialSourceKey")),this.fsData.hasProperty("initialAccountId")&&s.set("accountId",this.fsData.get("initialAccountId")),this.fsData.hasProperty("originalSize")&&s.set("originalSize",this.fsData.get("originalSize")),this.fsData.hasProperty("reducedSize")&&s.set("reducedSize",this.fsData.get("reducedSize")),this.fsData.hasProperty("showReduceSizeBanner")&&s.set("showReduceSizeBanner",this.fsData.get("showReduceSizeBanner")),this.fsData.hasProperty("reduceFileSizeSelectedByPref")&&s.set("reduceFileSizeSelectedByPref",this.fsData.get("reduceFileSizeSelectedByPref")),_.extend(this.options,{fileSelectionDlgOptions:i}),this.options.appApi.selectionApi.selectFiles(n,i).then(_.bind(function(e){var t=this.options.appApi,n=t.saveAsApi,r=e.uploadedFileAttrs,i=[],s=[],o={},u="pdf",a="",f=!1,l=!1,c=!1,h,p,d=[],v;h=t.pluginsApi.getSelectedPluginId("file_selection_dlg"),c=t.connectorsApi.isConnectorPlugin(h)&&t.connectorsApi.isDesktopConnector(t.connectorsApi.getConnectorPluginName(h)),c||h==="my_recent_files_select"?$.each(r,function(e,t){t._proxy&&i.push(t._proxy)}):$.each(r,function(e,t){undefined===t._proxy&&s.push(t)}),t.displayApi.showSpinner(!0),n.isRunningInFileSaveAs()?(a=n.getFilename(),f=n.isRestrictEditingSelected(),l=n.isReduceFileSizeSelected(),u=n.getChosenFileExtension()||"",o={selectedExtension:u,saveAsFilename:a,closeWindow:!0},f!==undefined&&_.extend(o,{restrictEditing:f}),l!==undefined&&_.extend(o,{reduceFileSize:l}),c?(p=n.getCurrentFolderProxy(),p&&_.extend(o,{saveAsParentFolderObject:p}),v=n.getReplaceFileObj(),v&&(d.push(v._proxy),_.extend(o,{selectedFileObjects:d}))):_.extend(o,{selectedBHFiles:[{id:n.getReplaceFileId()}],saveAsParentFolderid:n.getCurrentFolderId()})):o={selectedBHFiles:s,selectedExtension:u,selectedFileObjects:i,closeWindow:!0},this.fsData.invoke("setSelectedFiles",o).then(_.bind(function(){this.options.appApi.displayApi.showSpinner(!1)},this))},this),_.bind(function(){this.options.appApi.displayApi.showSpinner(!0),this.fsData.invoke("cancelDialog").then(_.bind(function(){this.options.appApi.displayApi.showSpinner(!1)},this))},this))}},this))}}),e.LoadingFileSelectionDlgOp}),define("app/dev/ops/whats-new-dlg/loading-whats-new-dlg-op",["core/ac-core","app/ac-app","core/utils/util","core/ops/op","app/views/file-selection-dlg-view"],function(e,t,n){t.LoadingWhatsNewDlgOp=e.Op.extend({run:function(e){var r,i=this.options;return _.extend(this.options,{parentView:t.viewMgr}),n.isCEF()&&i.runningInWhatsNewView?r=t.viewMgr.getContentPageView(i):r=new t.WhatsNewDlgView(i),r.open(e)}})}),define("app/dev/ops/getting/getting-all-base-uris-op",["core/ac-core","app/ac-app","aicx/ac-aicx","core/ops/op"],function(e,t,n){return t.GettingAllBaseUrisOp=e.Op.extend({run:function(){var t=this.options,r=e.opFactory,i=n.opFactory;return $.when.apply(undefined,[r.create("GettingBaseFilesUrisOp",t).run(),r.create("GettingBaseCloudUrisOp",t).run()]).then(_.bind(function(){try{return Ac.Aicx&&(Ac.Aicx.baseCpdfUri=t.appApi.baseCloudUrisApi.getCpdfUri()),i.create("GettingBaseAicUrisOp",t).run()}catch(e){util.isDevTestEnvironment()&&alert(e.toString()),logException(e,this.context);if(!this.handler)throw e;this.handler(e,this.context)}},this),_.bind(function(e){try{if(e.errorString==="DCAPIUnsupported-Error410")return $.Deferred().reject(e).promise()}catch(t){util.isDevTestEnvironment()&&alert(t.toString()),logException(t,this.context);if(!this.handler)throw t;this.handler(t,this.context)}},this))}}),t.GettingAllBaseUrisOp}),define("app/dev/ops/getting/getting-storage-info-op",["core/ac-core","app/ac-app","core/utils/util","core/ops/op"],function(e,t,n){return t.GettingStorageInfoOp=e.Op.extend({run:function(){var t=this.options,n=e.opFactory;return $.when(n.create("GettingSystemFoldersOp",t).run(),n.create("GettingRootOp",t).run(),n.create("GettingConnectorsUiHelpersOp",_.extend({},t,{forceFresh:!1,useReaderSyncMode:!1})).run())}}),t.GettingStorageInfoOp}),define("app/dev/ops/listening/listening-for-ajax-events-op",["core/ac-core","app/ac-app","core/utils/util","core/utils/ajax-util","core/ops/op"],function(e,t,n,r){t.ListeningForAjaxEventsOp=e.Op.extend({run:function(){var e=$.Deferred();return r.addGlobalAjaxHandlers({ajaxStart:this._onAjaxStart,ajaxSend:this._onAjaxSend,ajaxComplete:this._onAjaxComplete,ajaxStop:this._onAjaxStop,ajaxError:this._onAjaxError}),this._deferred=e,e.promise()},_onAjaxStart:function(){this.options.networkUiModel.set("is_ajax_request_active",!0)},_onAjaxSend:function(e,t,n){var r=n.modal;_.isUndefined(r)&&(r=!0),r&&this._showModalUi(!0)},_onAjaxComplete:function(e,t,r){var i=this.options,s=i.appApi,o=Ac.Plugins.rna_resource_url,u=r.modal,a;_.isUndefined(u)&&(u=!0),u&&this._showModalUi(!1),n.isCEF()&&(r.url.startsWith(o)||(a=t.status===0?!1:!0,a!==s.networkConnectivityApi.isOnline()&&i.networkConnectivityModel.set({is_connected:a,ajax_status:a})))},_onAjaxStop:function(){this.options.networkUiModel.set("is_ajax_request_active",!1)},_onAjaxError:function(t,r,i,s){var o=this.options,u=o.appApi,a=r.status,f,l;n.isCEF()&&(f=a===0?!1:!0,f===!1&&u.rnaApi.done(function(e){var t;e.isFeatRunning()&&e.isASTestAllowInstantiation()&&(t="jqXHR.statusText = ",t+=r.statusText,t+="\n",t+="jqXHR.status = ",t+=r.status,t+="\n",t+="jqXHR.state = ",t+=r.state(),t+="\n",t+="thrownError = ",t+=s,t+="\n",t+="ajaxSettings.url = ",t+=i.url,t+="\n",t+="ajaxSettings.base_url = ",t+=i.base_url,console.log("Ajax call error due to either network being offline or something else."),console.log(t))}),f!==u.networkConnectivityApi.isOnline()&&o.networkConnectivityModel.set({is_connected:f,ajax_status:f}));if(a===0||r.readyState===0)return;u.errorApi.logAjaxError(r),_.isUndefined(i.ignoreErrors)||(l=_.find(i.ignoreErrors,function(e){return e===404}));if(a===401)u.sessionApi.signedOut(),e.Util.isClassic()||o.errorUiModel.enqueueAjaxError(r);else if(a!==200){if(a===410)return;if(a===404&&!_.isUndefined(l))return;o.errorUiModel.enqueueAjaxError(r)}},_showModalUi:function(t){function u(t){if(e.isJasmine())return;if(!o)return;o.displayApi.showSpinner(t)}var n=this.options,r,i=n.ajaxUiModel,s=n.modalMaskUiModel,o=n.appApi;o.displayApi.isDebugLogging()&&LOG("AcApp.ListeningForAjaxEventsOp._showModalUi "+t),r=_.bind(function(){var e=this._ajaxSpinnerThresholdTimerId;e&&(clearTimeout(e),this._ajaxSpinnerThresholdTimerId=undefined),e=this._ajaxTransparentThresholdTimerId,e&&(clearTimeout(e),this._ajaxTransparentThresholdTimerId=undefined)},this),t?(n.ajaxModalRefs+=1,s.set({modal:!0,modal_ajax:!0,modal_transparent:!0}),this._ajaxSpinnerThresholdTimerId||(this._ajaxSpinnerThresholdTimerId=setTimeout(function(){s.get("modal")&&(n.ajaxSpinnerShown||(n.ajaxSpinnerShown=!0,u(!0)))},i.get("ajax_spinner_threshold"))),this._ajaxTransparentThresholdTimerId||(this._ajaxTransparentThresholdTimerId=setTimeout(_.bind(function(){s.get("modal")&&s.set("modal_transparent",!1)},this),i.get("ajax_transparent_threshold")))):(r(),n.ajaxModalRefs-=1,n.ajaxModalRefs<=0&&(s.set("modal_ajax",!1),o.dialogApi.isDialogOpen()||s.set("modal",!1),n.ajaxSpinnerShown&&(n.ajaxSpinnerShown=!1,u(!1))))}})}),define("app/dev/ops/listening/listening-for-download-errors-op",["core/ac-core","app/ac-app","core/utils/event-util","core/ops/op"],function(e,t,n){return t.ListeningForDownloadErrorsOp=e.Op.extend({run:function(){var e=this.options,t;return t=function(t){var n,r,i;try{n=JSON.parse(t.data),i=Ac.baseFilesUrisModel.getDownloadUri(),i&&i.indexOf(t.origin)===0&&n.name==="file-download-error"&&_.has(n,"status")&&(r={status:n.status,responseText:JSON.stringify(n.body)},e.appApi.errorApi.logAjaxError(r),e.appApi.errorApi.enqueueAjaxError(r))}catch(s){LOG(s)}},n.addPostMessageListener(t),this._getResolvedPromise()}}),t.ListeningForDownloadErrorsOp}),define("app/dev/ops/listening/listening-for-folder-notifications-op",["core/ac-core","app/ac-app","core/utils/util","core/utils/http-util","core/ops/op"],function(e,t,n,r){t.ListeningForFolderNotificationsOp=e.Op.extend({run:function(){var t=this.options,n=e.opFactory;return this._creatingEndpointsOp=n.create("CreatingNotificationsEndpointsOp",t),this._gettingFolderNotificationsOp=n.create("GettingFolderNotificationsOp",t),this._enablingFolderNotificationsOp=n.create("EnablingFolderNotificationsOp",t),this._addAppApiCallbacks(),this._addUiModelEventListeners(),this.options.appApi.sessionApi.isSignedIn()&&this._restart("initial"),$.Deferred().promise()},_start:function(){var t=this.options,r=t.appApi,i,s=t.notificationUiModel,o=t.appApi.pluginsApi;if(r.acrobatApi.isInAcrobat()&&e.Util.isMac())return this._getRejectedPromise();if(n.isCEF()&&!r.selectionApi.isRunningInFull())return this._getRejectedPromise();if(n.isCEF())if(!t.appApi.selectionApi.isRunningInFull()||o.getSelectedPluginId("tools")!=="home")return this._getRejectedPromise();return i=_.bind(function(e,t,r){n.isCEF()&&s.set("is_starting_notification",!1),this._onError(e,t,r)},this),this._creatingEndpointsOp.run().then(_.bind(function(){return this._startResubscribeTimer(),this._monitorFolders().then(_.bind(function(){this._isGetting||(this._gettingFolderNotificationsOp.run(),this._isGetting=!0)},this))},this),i)},_monitorFolders:function(){var e=this.options,t,n=e.notificationUiModel;return this._enablingFolderNotificationsOp.run(n.getFolderIds()).fail(_.bind(function(e,r,i){if(e.status===404)try{t=JSON.parse(e.responseText).error,t.code==="ObjectNotFound"&&n.removeCallback(t.details.id)}catch(s){}else this._onError(e,r,i)},this))},_stop:function(){return this._cancelPending(),e.opFactory.create("StoppingNotificationsOp",this.options).run()},_restart:function(e){function s(e){return _.isBoolean(e)&&n.set("is_restarting",e),n.get("is_restarting")}var t=this.options,n=t.notificationUiModel,r,i;if(s())return;s(!0),_.isUndefined(this._prevRestartTime)?this._prevRestartTime=(new Date).getTime():(r=(new Date).getTime(),i=r-this._prevRestartTime,i=500&&(this._debounced500Listener||(o=s.get("restart_500_debounce_delay"),this._debounced500Listener=_.debounce(_.bind(function(){this._restart(n)},this),o)),this._debounced500Listener())},_startResubscribeTimer:function(){var e=this.options.notificationUiModel,t;this._stopResubscribeTimer(),t=_.delay(_.bind(function(){this._restart("resubscribe timer")},this),e.get("resubscribe_timeout")),e.set("resubscribe_timeout_id",t)},_stopResubscribeTimer:function(){var e=this.options.notificationUiModel,t=e.get("resubscribe_timeout_id");t&&(window.clearTimeout(t),e.unset("resubscribe_timeout_id"))},_addAppApiCallbacks:function(){var e=this.options.appApi;e.sessionApi.addSignedInChangeCallback(this._onSignedInChange),e.inactivityApi.addIdleChangeCallback(this._onIsIdleChange),n.isCEF()&&e.networkConnectivityApi.addNetworkConnectivtyChangeCallback(this._onIsConnectivityChange)},_onSignedInChange:function(e,t){t?this._restart("signed in"):this._stop()},_onIsIdleChange:function(e,t){t?this._stop():this.options.appApi.sessionApi.isSignedIn()&&this._restart("no longer idle")},_onIsConnectivityChange:function(e,t){t?this.options.appApi.sessionApi.isSignedIn()&&this._restart():this._stop()},_addUiModelEventListeners:function(){this.options.notificationUiModel.on("change:callbacks_by_folder_id",this._onCallbacksByFolderIdChange).on("change:resubscribe_trigger",this._onResubscribeTriggerChange)},_onCallbacksByFolderIdChange:function(){this._monitorFolders()},_onResubscribeTriggerChange:function(e,t){t&&this._restart("404 resubscribe")}})}),define("app/dev/ops/listening/listening-for-inactivity-op",["core/ac-core","app/ac-app","core/utils/util","core/ops/op"],function(e,t,n){t.ListeningForInactivityOp=e.Op.extend({run:function(){var e=$.Deferred(),t=this.options;return this._addActivityListeners(),this._addUiModelEventListeners(),t.notificationModel.get("update_url")?this._startInactivityTimer():n.isCEF()&&t.appApi.rnaApi.then(_.bind(function(){t.inactivityUiModel.get("timeout_id")||this._startInactivityTimer()},this)),e.promise()},_startInactivityTimer:function(){var e=this.options.inactivityUiModel;this._stopInactivityTimer(),e.set({is_active:!1,is_idle:!1},{silent:!0}),e.set("timeout_id",_.delay(function(){e.get("is_active")||(LOG(0,"AcApp.ListeningForInactivityOp._startInactivityTimer: setting is_idle=true"),e.set("is_idle",!0))},e.get("idle_timeout")),{silent:!0})},_stopInactivityTimer:function(){var e=this.options.inactivityUiModel,t;t=e.get("timeout_id"),t&&(clearTimeout(t),e.unset("timeout_id"))},_addActivityListeners:function(){var e=this.options.inactivityUiModel,t,n;t=_.debounce(_.bind(function(){this._startInactivityTimer()},this),e.get("restart_debounce_delay")),n=function(n){e.set({is_active:!0,is_idle:!1}),t(n)},$("body").on("mousemove.inactivity",n).on("click.inactivity",n).on("keydown.inactivity",n)},_addUiModelEventListeners:function(){this.options.inactivityUiModel.on("change:is_idle",this._onIsIdleChange)},_onIsIdleChange:function(t,n){var r=this.options,i,s;n?(i=r.sessionUiModel,s=i.get("refresh_timer_id"),s&&(window.clearTimeout(s),i.unset("refresh_timer_id"))):t.previous("is_idle")===!0&&r.signInUiModel.get("is_signed_in")&&e.opFactory.create("RefreshingSessionInitiallyOp",r).run()}})}),define("app/dev/ops/listening/listening-for-network-connectivity-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){t.ListeningForNetworkConnectivityOp=e.Op.extend({run:function(){var e=$.Deferred();return this._addConnectivityListeners(),this._deferred=e,e.promise()},_addConnectivityListeners:function(){var e=this.options.networkConnectivityModel,t=this.options.appApi,n;t.rnaApi.done(function(e){e.isFeatRunning()&&e.isASTestAllowInstantiation()&&console.log(navigator.onLine?"network connectivity status while loading this renderer is connected":"network connectivity status while loading this renderer is notConnected")}),n=function(){t.rnaApi.done(function(t){var n;t.isFeatRunning()&&t.isASTestAllowInstantiation()&&(n="network connectivity changed from ",n+=e.get("is_connected")?"connected":"notConnected",n+=" to ",n+=navigator.onLine?"connected":"notConnected",console.log(n))}),e.set({is_connected:navigator.onLine,ajax_status:navigator.onLine})},window.addEventListener("online",n,!1),window.addEventListener("offline",n,!1)}})}),define("app/dev/ops/listening/listening-for-server-errors-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){t.ListeningForServerErrorsOp=e.Op.extend({run:function(){var e=$.Deferred();return this._addUiModelEventListeners(),this._deferred=e,e.promise()},_showError:function(){var e=this.options,t=e.errorUiModel,n=t.get("error"),r,i=e.appApi,s;if(!i)return;s=i.dialogApi,n&&(r=t.getErrorStrings(n),s.displayTextAlert(s.SEVERITY_ERROR,r.title,r.msg,r.btn1).always(_.bind(function(){this._onButtonClick()},this)))},_onButtonClick:function(){var e=this.options,n=e.errorUiModel.get("error"),r,i=t.opFactory;if(!n)return;r=n.data.status,r===401?i.create("SigningInFromErrorOp",e).run():r===403?i.create("ShowingNextErrorOp",e).run():i.create("ShowingNextErrorOp",e).run()},_addUiModelEventListeners:function(){this.options.errorUiModel.on("change:error",this._onErrorChange)},_onErrorChange:function(t,n){if(n&&n.type!==e.ErrorUiModel.ERROR_TYPE_AJAX&&n.type!==e.ErrorUiModel.ERROR_TYPE_MISC)return;this._showError()}})}),define("app/dev/ops/listening/listening-for-view-events-op",["core/ac-core","app/ac-app","core/ops/op","core/views/view-events","app/views/view-events"],function(e,t){t.ListeningForViewEventsOp=e.Op.extend({initialize:function(){e.Op.prototype.initialize.call(this),this._initEventMap()},run:function(){var e=$.Deferred();return t.viewMgr.on("all",this._onViewEvent),this._deferred=e,this._deferred.resolve(),e.promise()},_onViewEvent:function(t,n){var r,i;r=this._eventMap[t],r&&(i=r[0].create(r[1],n));if(!i){t!==e.ViewEvents.MENU_CLOSED&&LOG(0,"AcApp.ListeningForViewEventsOp._onViewEvent ignoring "+t);return}i.run().then(function(){return undefined},function(){return undefined})},_mapEvent:function(e,t,n,r,i){e[t]=[n,r,i]},_initEventMap:function(){var e,n,r,i;e=this._eventMap={},n=this._mapEvent,r=t.opFactory,i=t.ViewEvents,n(e,i.ACCOUNT_MENU_ITEM_CLICK,r,"SelectingAccountMenuItemOp"),n(e,i.ACCOUNT_MENU_BTN_CLICK,r,"TogglingAccountMenuOp"),n(e,i.HELP_MENU_BTN_CLICK,r,"TogglingHelpMenuOp"),n(e,i.ABOUT_CLICK,r,"NavigatingToAboutDlgOp"),n(e,i.ASK_US_CLICK,r,"ShowingUserForumOp"),n(e,i.SUPPORT_CLICK,r,"ShowingSupportHomeOp"),n(e,i.CHAT_WITH_US_CLICK,r,"ShowingChatPodOp"),n(e,i.TOOLBAR_ITEM_CLICK,r,"SelectingToolOp"),n(e,i.ACCOUNT_MENU_ITEM_CLICK,r,"SelectingAccountMenuItemOp"),n(e,i.ACROBAT_SELECT_FILTER,r,"SelectingAcrobatFilterOp"),n(e,i.ACROBAT_OPEN,r,"OpeningInAcrobatOp"),n(e,i.ACROBAT_CLOSE,r,"ClosingInAcrobatOp")}})}),define("app/dev/ops/listening/listening-for-window-events-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){t.ListeningForWindowEventsOp=e.Op.extend({initialize:function(){e.Op.prototype.initialize.call(this),this._updateWindowUiModel(!0)},run:function(){var e,t=$.Deferred();return e=$(window),e.resize(_.bind(function(){this._updateWindowUiModel(!1)},this)),this._deferred=t,this._deferred.resolve(),t.promise()},_updateWindowUiModel:function(e){var t=$(window),n=t.width(),r=t.height();if(this._oldWidth!==n||this._oldHeight!==r)this._oldWidth=n,this._oldHeight=r,this.options.windowUiModel.set({width:n,height:r},{silent:e})}})}),define("app/dev/ops/misc/handling-uncaught-exceptions-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){var n=0,r=10;return t.HandlingUncaughtExceptionsOp=e.Op.extend({run:function(){var e=this.options;return window.onerror=function(t,i,s,o,u){var a=e.appApi,f,l,c;if(!a)return!1;f=a.errorApi,l="window.onerror: "+t+" "+i+" line "+s,o&&(l+=", col "+o),u&&(c=u.stack,c&&(l+="\n"+c));try{f.notifyUncaughtExceptionCallbacks(t,i,s,o,u)&&n=768&&e<=1024&&r.loadCss("css/main-ipad.css"),(e<=480||i>.56&&i<.57)&&r.loadCss("css/main-iphone.css"),this._getResolvedPromise())}}),t.LoadingCustomCssOp}),define("app/dev/ops/misc/loading-deep-link-plugins-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){return t.LoadingDeepLinkPluginsOp=e.Op.extend({run:function(){var t=this.options,n=t.appApi.pluginsApi;return e.opFactory.create("LoadingPluginsOp",_.extend({pluginsConfig:n.getPluginTypeConfig("deep_link"),pluginsUiModel:t.deepLinkPluginsUiModel},_.pick(t,"appApi","pluginId","force"))).run()}}),t.LoadingDeepLinkPluginsOp}),define("app/dev/ops/misc/loading-framework-versions-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){return t.LoadingFrameworkVersionsOp=e.Op.extend({run:function(){var t=e.opFactory,n=[];return _.each(Ac.config.frameworkVersions,function(e){n.push(t.create("LoadingModuleOp").run({displayName:"Framework version "+e,url:"versions/framework-"+e}))}),$.when.apply(this,n)}}),t.LoadingFrameworkVersionsOp}),define("app/dev/ops/misc/loading-plugin-configs-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){return t.LoadingPluginConfigsOp=e.Op.extend({run:function(){function f(){u+=1,u===o&&e.resolve()}function l(e){var t=n[e];return!_.isUndefined(_.find(r,function(e){return _.find(e.plugin_ids,function(e){return!_.isUndefined(t[e])})}))}var e=$.Deferred(),t=Ac.Plugins,n=t.groups,r=t.types,i=this.options.appApi.pluginsApi,s,o=0,u=0,a;return o=_.reduce(n,function(e,t){return t.config_url&&(e+=1),t.analytics_url&&(e+=1),e},0),o===0?e.resolve():(_.each(_.keys(n),function(e){if(!l(e)){LOG("AcApp.LoadingPluginConfigsOp.run '"+e+"' group has no configured plugins"),f();return}s=i.getGroupConfigUrl(e),s&&require([s],function(){i.setPluginGroupConfigLoaded(e,!0),f()},function(e){LOG("Ac.LoadingPluginConfigsOp.run '"+e.requireModules[0]+"' failed to load"),f()}),a=i.getGroupAnalyticsUrl(e),a&&require([a],function(){f()},function(e){LOG(0,"Ac.LoadingPluginConfigsOp.run '"+e.requireModules[0]+"' failed to load"),f()})}),e.promise())}}),t.LoadingPluginConfigsOp}),define("app/dev/ops/misc/loading-plugin-configs-versions-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){return t.LoadingPluginConfigsVersionsOp=e.Op.extend({run:function(){var t=this.options,n=[],r,i;return i=e.opFactory.create("LoadingFrameworkVersionOp",t),_.each(Ac.Plugins.groups,function(e){r=e.FRAMEWORK_VERSION,r&&n.push(i.run(r))}),$.when.apply(this,n)}}),t.LoadingPluginConfigsVersionsOp}),define("app/dev/ops/misc/loading-rna-variant-info-op",["core/ac-core","app/ac-app","core/utils/util","core/ops/op"],function(e,t,n){return t.LoadingRNAVariantInfoOp=e.Op.extend({run:function(){var e=$.Deferred(),t,r=this.options;return n.isCEF()?Ac.config.getEnvironment()==="dev"||Ac.config.getEnvironment()==="local"||Ac.config.getEnvironment()==="lint"?e.resolve().promise():(t=window.location.origin+"/variant.js",Ac.currentRNAVariants={},r.appApi.rnaApi.done(_.bind(function(t){var n=t.getVariantJsonFromRegistry();if(n&&n.length>0){var r=JSON.parse(n);r&&r[0]&&$.each(r[0],function(e,t){Ac.currentRNAVariants[e]=t})}e.resolve()},this),_.bind(function(){e.resolve()},this)),e.promise()):e.resolved().promise()}}),t.LoadingRNAVariantInfoOp}),define("app/dev/ops/misc/loading-rna-version-info-op",["core/ac-core","app/ac-app","core/utils/util","core/ops/op"],function(e,t,n){return t.LoadingRNAVersionInfoOp=e.Op.extend({run:function(){var t=$.Deferred(),r,i,s;return n.isCEF()?(r=Ac.config.getEnvironment(),r==="dev"||r==="local"||r==="lint"?t.resolve().promise():(i=e.getBaseCloudUrl()+"rnaversion.js",s=window.location.origin+"/version.js",$.getJSON(s,function(e){var n;e?(Ac.currentRNAVersions={},n=_.values(e),_.each(n,function(e){_.each(e.plugin_ids,function(t){Ac.currentRNAVersions[t]=e["rna-version"]})}),t.resolve()):t.resolve()}),t.promise())):t.resolved().promise()}}),t.LoadingRNAVersionInfoOp}),define("app/dev/ops/misc/loading-template-plugins-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){return t.LoadingTemplatePluginsOp=e.Op.extend({run:function(){var t=this.options,n=t.appApi.pluginsApi,r=t.templatePluginsUiModel;return r.set("instantiate_on_load",!1),e.opFactory.create("LoadingPluginsOp",_.extend({pluginsConfig:n.getPluginTypeConfig("template"),pluginsUiModel:r},_.pick(t,"appApi","pluginId","force"))).run()}}),t.LoadingTemplatePluginsOp}),define("app/dev/ops/misc/loading-typekit-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){return t.LoadingTypekitOp=e.Op.extend({run:function(){var e={kitId:"eow2xot",scriptTimeout:3e3},t=document.getElementsByTagName("html")[0];t.className+=" wf-loading";var n=setTimeout(function(){t.className=t.className.replace(/(\s|^)wf-loading(\s|$)/g," "),t.className+=" wf-inactive"},e.scriptTimeout),r=document.createElement("script"),i=!1;r.src="//use.typekit.net/"+e.kitId+".js",r.type="text/javascript",r.async="true",r.onload=r.onreadystatechange=function(){var t=this.readyState;if(i||t&&t!="complete"&&t!="loaded")return;i=!0,clearTimeout(n);try{Typekit.load(e)}catch(r){}};var s=document.getElementsByTagName("script")[0];return s.parentNode.insertBefore(r,s),this._getResolvedPromise()}}),t.LoadingTypekitOp}),define("app/dev/templates/about-dlg-template",[],function(){return'
<%= trademarkPara %>
<%= portionsPara %>
<%= microsoftPara %>
<%= irisPara %>
<%= solidPara %>
<%= thirdPartyPara %>
<%= buildNum %>
'}),define("build-url",["core/ac-core"],function(e){e.buildUrl="#",e.buildNumber="000001",e.buildBranch="local/unknown",e.buildCommit="this-is-a-fake-gitish---of-proper-length",e.buildUntaggedVersion="1.0.0L",e.buildTaggedVersion="1.0.0L.dev000001"}),define("app/dev/views/about-dlg-view",["core/ac-core","app/ac-app","app/templates/about-dlg-template","i18n!core/nls/ui-strings","i18n!app/nls/ui-strings","core/utils/sc-analytics","core/utils/truncate","core/views/dialog-view","build-url"],function(e,t,n,r,i,s,o){var u="adobe.skybox.";t.AboutDlgView=e.DialogView.extend({events:function(){return _.extend({},e.DialogView.prototype.events,{"click .about-dlg-ok-btn":"_onOkClick","click .about-dlg-build-num":"_onBuildNumClick","click .about-dlg-third-party-link":"_onThirdPartyClick"})},initialize:function(){e.DialogView.prototype.initialize.call(this)},render:function(){return e.DialogView.prototype.render.call(this),this._appendToDialog(_.template(n)({copyrightPara:i.ABOUT_DLG_COPYRIGHT_PARA,trademarkPara:i.ABOUT_DLG_TRADEMARK_PARA,portionsPara:i.ABOUT_DLG_PORTIONS_PARA,microsoftPara:i.ABOUT_DLG_MICROSOFT_PARA,irisPara:i.ABOUT_DLG_IRIS_PARA,solidPara:i.ABOUT_DLG_SOLID_PARA,thirdPartyPara:this._getThirdPartyPara(),buildNum:this._getBuildNumText(),okBtn:r.OK})),this._initWrappers(),this._center(),this._truncateText(),this.$okBtn.focus(),this},close:function(t,n){return(!n||!n.noHistoryEffect)&&window.history.back(),e.DialogView.prototype.close.call(this,t,n)},_initWrappers:function(){e.DialogView.prototype._initWrappers.call(this),this.$title=this.$(".about-dlg-title"),this.$thirdPartyLink=this.$(".about-dlg-third-party-link"),this.$okBtn=this.$(".about-dlg-ok-btn"),this.$pluginVersions=this.$(".about-dlg-plugin-versions")},_getThirdPartyPara:function(){var e=this._getLocalizedThirdPartyUrl();return _.template(i.ABOUT_DLG_THIRD_PARTY_PARA,{thirdPartyLink:""+e+""})},_getLocalizedThirdPartyUrl:function(){var t=e.Locale.getImsLocale(),n=t.substr(0,2),r=e.Config;return n==="en"?r.THIRD_PARTY_URL:(n==="ja"?n="jp":n==="nb"&&(n="no"),_.template(r.THIRD_PARTY_URL_TEMPLATE,{loc:n}))},_getBuildNumText:function(){return _.template(i.ABOUT_DLG_BUILD_NUMBER,{buildNum:e.buildTaggedVersion.replace(u,"")})},_truncateText:function(){o.truncateElementText(this.$title),o.truncateButtonLabel(this.$okBtn)},_showAllVersions:function(){var e=_.extend({},this.options,{force:!0}),n=e.appApi,r=n.displayApi,i=t.opFactory,s,o,a,f=this.$pluginVersions;s=i.create("LoadingAccountMenuOp",e),o=i.create("LoadingToolsOp",e),a=i.create("LoadingFileSelectionDlgHomeViewsOp",e),r.showSpinner(!0),$.when(s.run(),o.run(),a.run()).then(_.bind(function(){var t=e.appApi.pluginsApi.getVersionLists(),n=[];f.empty().append("Plugin Versions
"),_.each(t,function(e,t){var r=e.versionList;n.push(r),$.when(r).then(function(){f.append(t+": "),_.each(r,function(t){t&&f.append(t.replace(u,"")+" "+e.frameworkVersion)}),f.append("
")})}),this._center(),$.when.apply($,n).always(_.bind(function(){r.showSpinner(!1),this._center()},this))},this))},_onHistoryChange:function(){this.options.appApi.routerApi.isCurrentPath("about")||e.DialogView.prototype._onHistoryChange.call(this)},_onOkClick:function(){this.close()},_onBuildNumClick:function(){this._showAllVersions()},_onThirdPartyClick:function(){this._logSiteCatalystEvent([s.ADOBE_DOT_COM,s.PRODUCTS,s.EULA,s.THIRD_PARTY])}})}),define("app/dev/ops/misc/navigating-to-about-dlg-op",["core/ac-core","app/ac-app","core/ops/op","app/views/about-dlg-view"],function(e,t){return t.NavigatingToAboutDlgOp=e.Op.extend({run:function(){return this.options.appApi.routerApi.navigate("about",{trigger:!0}),this._getResolvedPromise()}}),t.NavigatingToAboutDlgOp}),define("app/dev/ops/misc/overriding-jquery-ajax-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){return t.OverridingJQueryAjaxOp=e.Op.extend({run:function(){var e=$.ajax,t,n,r;return $.ajax=function(i,s){return s&&s.async===!1?(t=$.Deferred(),n=s.success,s.success=function(e,r,i){n&&n.call(undefined,e,r,i),t.resolve(e,r,i)},r=s.error,s.error=function(e,n,i){r&&r.call(undefined,e,n,i),t.reject(e,n,i)},e.call($,i,s),t.promise()):e.call($,i,s)},this._getResolvedPromise()}}),t.OverridingJQueryAjaxOp}),define("app/dev/ops/misc/redirecting-to-apollo-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){return t.RedirectingToApolloOp=e.Op.extend({run:function(){var t=this.options,n=t.appApi,r=t.usersMeSubscriptionsModel.get("subscriptions"),i,s=!0,o,u=n.usersMeApi.getCommonUserPrefs().lastToolUsed,a=n.routerApi.getPathname();if(e.Features.isFeatureEnabled("redirect_to_apollo")){if(_.isArray(r))for(o=0;o0?(o=_.sortBy(o,function(e){return e}),s.displayHtmlAlert(s.SEVERITY_ERROR,n.LOAD_FAILURES,_.template(n.MODULES_NOT_LOADED,{modules:o.join("
")}))):$.Deferred().resolve().promise()}}),t.ShowingLoadFailuresDlgOp}),define("app/dev/ops/misc/showing-next-error-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){t.ShowingNextErrorOp=e.Op.extend({run:function(){return this.options.errorUiModel.dequeueError(),this._getResolvedPromise()}})}),define("app/dev/ops/misc/showing-support-home-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){t.ShowingSupportHomeOp=e.Op.extend({run:function(){var t;return this.options.pageHeaderUiModel.set("show_account_menu",!1),t=_.template(e.Config.SUPPORT_URL,{locale:e.Locale.getHelpLocale()}),window.open(t),this._getResolvedPromise()}})}),define("app/dev/ops/misc/showing-user-forum-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){t.ShowingUserForumOp=e.Op.extend({run:function(){var t;return this.options.pageHeaderUiModel.set("show_account_menu",!1),t=_.template(e.Config.FORUM_URL,{locale:e.Locale.getHelpLocale()}),window.open(t),this._getResolvedPromise()}})}),define("app/dev/ops/misc/starting-history-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){return t.StartingHistoryOp=e.Op.extend({run:function(){var e=this.options.appApi.routerApi,t,n,r,i={pushState:!0};n=!e.hasPushState()&&e.getPathname().indexOf("/send/jump")===0,n&&(i.pushState=!1,i.silent=!0),Backbone.History.started&&LOG.warn("AcApp.StartingHistoryOp.run: Already started",{logServer:!0}),t=Backbone.history;try{t.start(i)}catch(s){LOG.warn("AcApp.StartingHistoryOp: "+(s.stack||s.message),{logServer:!0})}return n&&(r=t.getFragment(null,!0),t.loadUrl(r)),$.Deferred().resolve().promise()}}),t.StartingHistoryOp}),define("app/dev/ops/misc/switching-language-op",["core/ac-core","app/ac-app","core/utils/cookie-util","core/utils/util","core/ops/op","jquery.cookie"],function(e,t,n,r){t.SwitchingLanguageOp=e.Op.extend({run:function(){var t=this.options;return r.isCEF()||(n.setCookie(e.Config.LANGUAGE_COOKIE,e.Locale.getImsLocale(t.locale)),t.appApi.routerApi.reloadPage({reason:"Switching language"})),this._getResolvedPromise()}})}),define("app/dev/ops/misc/toggling-account-menu-op",["core/ac-core","app/ac-app","core/utils/sc-analytics","core/ops/op"],function(e,t,n){t.TogglingAccountMenuOp=e.Op.extend({run:function(){var e=this.options,t=e.pageHeaderUiModel,r;return r=!t.get("show_account_menu"),t.set("show_account_menu",r),r&&e.appApi.siteCatalystApi.logScEvent([n.TOP_HEADER,n.USER_ACCOUNT_MENU,n.SHOWN]),this._getResolvedPromise()}})}),define("app/dev/ops/misc/toggling-help-menu-op",["core/ac-core","app/ac-app","core/utils/sc-analytics","core/ops/op"],function(e,t,n){t.TogglingHelpMenuOp=e.Op.extend({run:function(){var e=this.options,t=e.pageHeaderUiModel,r;return r=!t.get("show_help_menu"),t.set("show_help_menu",r),r&&e.appApi.siteCatalystApi.logScEvent([n.TOP_HEADER,n.HELP_MENU,n.SHOWN]),this._getResolvedPromise()}})}),define("app/dev/ops/misc/validating-rna-version-info-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){return t.ValidatingRNAVersionInfoOp=e.Op.extend({run:function(e){var t=this.options,n,r,i=t.appApi.pluginsApi;return!Ac.rnaVersionInfo||!Ac.currentRNAVersions?this._getResolvedPromise():(r=i.getMinimumSupportedRNAVersion(e),n=i.getRNAVersion(e),n=0)return!0;return!1},_containsImageURL:function(e){return e.indexOf("url")>=0&&this._hasImageExtension(e)?!0:!1},_shouldURLbeChanged:function(e,t){if(e.indexOf("themeless")>-1)return!1;var n="/themes/dark/";return t=="dark"?e.indexOf(n)>-1?!1:!0:e.indexOf(n)>-1?!0:!1},_getContentOrBackground:function(e){var t,n,r;return t=undefined,_.isUndefined(e)||_.isUndefined(e.content)&&_.isUndefined(e.backgroundImage)?undefined:(n=e.content,r=e.backgroundImage,!_.isUndefined(r)&&this._containsImageURL(r)&&(t="backgroundImage"),!_.isUndefined(n)&&this._containsImageURL(n)&&(t="content"),t)},_processRule:function(e,t){var n,r,i,s,o,u;if(e.type===CSSRule.STYLE_RULE)r=e.style,n=this._getContentOrBackground(r),!_.isUndefined(n)&&!_.isUndefined(r)&&(i=r[n],t=="dark"?this._shouldURLbeChanged(i,t)&&(i=i.split("/"),i.splice(i.length-1,0,"themes",t),i=i.join("/"),r[n]=i):this._shouldURLbeChanged(i,t)&&(i=i.replace("/themes/dark",""),r[n]=i));else if(e.type===CSSRule.MEDIA_RULE){s=e.cssRules;for(u=0;u>16,n=e>>8&255,r=e&255),i=Math.sqrt(.299*t*t+.587*n*n+.114*r*r),i>127.5?"light":"dark"},_updateThemeContainerBackgroundColor:function(e){var t=this.lightOrDark(e);t=="dark"?this._updateCssSelectorStyle(".ui-theme.theme-container.convert","background-color","#3E3E3E"):this._updateCssSelectorStyle(".ui-theme.theme-container.convert","background-color","#F5F5F5"),this._updateCssSelectorStyle(".ui-theme.theme-container","background-color",e),this._updateCssSelectorStyle(".ui-theme-notch-color","color",e)},_updateThemeContainerProminentBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme.theme-container-prominent","background-color",e)},_updateThemeFrameColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-frame","border-color",e)},_updateThemeSelectableContentColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-selectable","color",e)},_updateThemeSelectableContentBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-selectable","background-color",e)},_updateThemeSelectableContentFocusColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-selectable:hover","background-color",e)},_updateThemeSelectableContentHoverColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-selectable:focus","background-color",e)},_updateThemeHoverableContentColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-hoverable:hover","color",e),this._updateCssSelectorStyle(".ui-theme .theme-hoverable:focus","color",e),this._updateCssSelectorStyle(".ui-theme .theme-hoverable:hover div","color",e)},_updateThemeHoverableContentBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-hoverable:hover","background-color",e),this._updateCssSelectorStyle(".ui-theme .theme-hoverable:focus","background-color",e),this._updateCssSelectorStyle(".ui-theme .theme-hoverable:hover div","background-color",e)},_updateThemeFocusColor:function(e){this._updateCssSelectorStyle("li:focus > span","outline-color",e),this._updateCssSelectorStyle(":focus","outline-color",e),this._updateCssSelectorStyle(":focus","outline-style","solid"),this._updateCssSelectorStyle(":focus","outline-width","2px")},_updateThemeBorderColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-border","border-color",e)},_updateThemeListItemRowBorderColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-file-list-row-border","border-color",e)},_updateThemeListItemRowBorderVirgoColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-file-list-row-border-virgo","background-color",e)},_updateThemeVirgoTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-virgo-text","color",e)},_updateThemeVirgoTextHoverColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-virgo-text:hover","color",e),this._updateCssSelectorStyle(".ui-theme .theme-virgo-text:focus","color",e)},_updateThemeVirgoTextCheckedColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-virgo-text.selected","color",e)},_updateThemeVirgoBasicTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-virgo-basic-text","color",e)},_updateThemeVirgoBasicTextHoverColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-virgo-basic-text:hover","color",e),this._updateCssSelectorStyle(".ui-theme .theme-virgo-basic-text:focus","color",e)},_updateThemeVirgoBasicTextCheckedColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-virgo-basic-text.selected","color",e)},_updateThemeVirgoHeaderTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-virgo-header-text","color",e),this._updateCssSelectorStyle(".ui-theme .theme-page-header.multi-parcel","color",e)},_updateThemeVirgoHeaderTextHoverColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-virgo-header-text:hover","color",e),this._updateCssSelectorStyle(".ui-theme .theme-virgo-header-text:focus","color",e)},_updateThemeVirgoHeaderTextCheckedColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-virgo-header-text.selected","color",e)},_updateThemeListItemSubTextElemColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-list-item-sub-text","color",e)},_updateThemeListItemTextElemColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-list-item-text","color",e)},_updateThemeFileListColTextElemColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-file-list-col-header","color",e)},_updateThemeFileListRowHeaderTextElemColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-file-list-row-header","color",e)},_updateThemeFileListRowHeaderHoverTextElemColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-file-list-row-header:hover","color",e)},_updateThemeFileListRowHeaderActiveTextElemColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-file-list-row-header.selected","color",e)},_updateThemeFileListRowItemTextElemColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-file-list-row-value","color",e)},_updateThemeFileListRowItemTextElemHoverColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-file-list-row-value:hover","color",e)},_updateThemeFileListRowItemTextElemSelectedColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-file-list-row-value.selected","color",e)},_updateThemeWorkflowPageHeaderTextElemColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-page-header","color",e)},_updateThemeListItemTextElemHoverColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-list-item:hover .theme-list-item-text","color",e)},_updateThemeListItemTextElemCheckedColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-list-item.selected .theme-list-item-text","color",e),this._updateCssSelectorStyle(".ui-theme .theme-list-item:focus .theme-list-item-text","color",e)},_updateThemeListitemBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-list-item","background-color",e)},_updateThemeListitem2BackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-list-item2","background-color",e)},_updateThemeListitemHoverColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-list-item:hover","background-color",e)},_updateThemeListitemCheckedColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-list-item.selected","background-color",e),this._updateCssSelectorStyle(".ui-theme .theme-list-item:focus","background-color",e)},_updateThemeListitemRowBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-list-item-row","background-color",e),this._updateCssSelectorStyle(".ui-theme .shared-theme-list-item-row","background-color",e),this._updateCssSelectorStyle(".ui-theme .theme-list-item-row-sort","background-color",e)},_updateThemeListitemRowHoverColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-list-item-row:hover","background-color",e),this._updateCssSelectorStyle(".ui-theme .theme-list-item-row-sort:hover","background-color",e)},_updateThemeListitemRowCheckedColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-list-item-row.selected","background-color",e),this._updateCssSelectorStyle(".ui-theme .theme-list-item-row.selected .shared-theme-list-item-row","background-color",e),this._updateCssSelectorStyle(".ui-theme .theme-list-item-row:focus","background-color",e),this._updateCssSelectorStyle(".ui-theme .shared-theme-list-item-row:focus","background-color",e),this._updateCssSelectorStyle(".ui-theme .theme-list-item-row-sort.selected","background-color",e)},_updateThemeThumbnailItemRowBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-thumbnail-item-row","background-color",e),this._updateCssSelectorStyle(".ui-theme .theme-thumbnail-item-row.selected","background-color",e),this._updateCssSelectorStyle(".ui-theme .theme-thumbnail-item-row:focus","background-color",e),this._updateCssSelectorStyle(".ui-theme .theme-thumbnail-item-row:hover","background-color",e)},_updateThemeThumbnailItemRowHoverColor:function(e){},_updateThemeThumbnailItemRowCheckedColor:function(e){},_updateThemeListitemRowVirgoBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-list-item-row-virgo","background-color",e)},_updateThemeListitemRowVirgoHoverColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-list-item-row-virgo:hover","background-color",e),this._updateCssSelectorStyle(".ui-theme .theme-list-item-row-virgo:focus","background-color",e)},_updateThemeListitemRowVirgoCheckedColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-list-item-row-virgo.selected","background-color",e)},_updateThemeRHPActionItemBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .rhp-actions-item","background-color",e)},_updateThemeRHPActionItemHoverColor:function(e){this._updateCssSelectorStyle(".ui-theme .rhp-actions-item:hover","background-color",e)},_updateThemeRHPActionItemActiveColor:function(e){this._updateCssSelectorStyle(".ui-theme .rhp-actions-item:active","background-color",e)},_updateThemeReviewerAvatarBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .avatar-background-themes","background-color",e)},_updateThemeReviewerAvatarBorderColorNormal:function(e){this._updateCssSelectorStyle(".ui-theme .avatar-border-themes","border-color",e)},_updateThemeReviewerAvatarBorderColorHover:function(e){this._updateCssSelectorStyle(".ui-theme .avatar-border-themes:hover","border-color",e)},_updateThemeVerticalTabTextElemColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-vertical-tab-text","color",e)},_updateThemeVerticalTabTextElemHoverColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-vertical-tab:hover .theme-vertical-tab-text","color",e),this._updateCssSelectorStyle(".ui-theme .theme-vertical-tab:focus .theme-vertical-tab-text","color",e)},_updateThemeVerticalTabTextCheckedElemColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-vertical-tab.selected .theme-vertical-tab-text","color",e)},_updateThemeVerticalTabBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-vertical-tab","background-color",e)},_updateThemeVerticalTabHoverColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-vertical-tab:hover","background-color",e),this._updateCssSelectorStyle(".ui-theme .theme-vertical-tab:focus","background-color",e)},_updateThemeVerticalTabCheckedColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-vertical-tab.selected","background-color",e)},_updateThemeTabButtonsBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-tab-button","background-color",e)},_updateThemeToolTipTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-tooltip-text","color",e)},_updateThemeToolTipBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-tooltip","background-color",e)},_updateThemeToolTipArrowColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-tooltip","color",e)},_updateThemeAddFilesColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-share-add-files","color",e)},_updateSharePaneBorderColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-share-border","border-color",e)},_updateShareContainerBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-share-container","background-color",e)},_updateShareGreyContainerBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-share-grey-container","background-color",e)},_updateSharePromoContainerBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-share-promo-container","background-color",e)},_updateModalShareContainerBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-share-modal-container","background-color",e)},_updateProtectModalContainerBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-protect-container","background-color",e)},_updateRedactContainerBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-redact-container","background-color",e)},_updateOauthDialogContainerBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-oauthdialog-container","background-color",e)},_updateDigSigContainerBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-digsig-container","background-color",e)},_updateDigSigListBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-digsig-list-background","background-color",e)},_updateShareInputContainerBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-share-input-container","background-color",e)},_updateShareModalInputContainerBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-share-modal-input-container","background-color",e)},_updateShareInputTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-share-input-text","color",e)},_updateNewBadgeBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-new-badge-background","background-color",e)},_updateNewBadgeTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-new-badge-text","color",e)},_updateShareGreyButtonBorderColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-share-grey-button","border-color",e)},_updateShareGreyButtonTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-share-grey-button","color",e)},_updateShareGreyButtonHoverBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-share-grey-button:hover","background-color",e)},_updateShareGreyButtonHoverTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-share-grey-button:hover","color",e)},_updateShareGreyButtonTransition:function(){this._updateCssSelectorStyle(".ui-theme .theme-share-grey-button","transition","none")},_updateThemeTabButtonsHoverColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-tab-button:hover","background-color",e),this._updateCssSelectorStyle(".ui-theme .theme-tab-button:focus","background-color",e)},_updateThemeTabButtonsCheckedColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-tab-button.selected","background-color",e)},_updateThemeWalkthroughElemBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-walkthrough","background-color",e)},_updateThemeWalkthroughTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-walkthrough-text","color",e)},_updateThemeWalkthroughSpectrumTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-spectrum-walkthrough-content","color",e)},_updateThemeWalkthroughSpectrumTitleColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-spectrum-walkthrough-title","color",e)},_updateThemeWalkthroughSpectrumBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-spectrum-walkthrough-background","background-color",e)},_updateThemePlaceholderColor:function(e){this._updateCssSelectorStyle(".ui-theme::-webkit-input-placeholder","color",e)},_updateBellHeaderBackground:function(e){this._updateCssSelectorStyle(".ui-theme .bell-header-theme","background-color",e)},_updateBellHeaderBackgroundHover:function(e){this._updateCssSelectorStyle(".ui-theme .bell-header-theme:hover","background-color",e),this._updateCssSelectorStyle(".ui-theme .bell-header-theme:focus","background-color",e)},_updateBellHeaderBackgroundActive:function(e){this._updateCssSelectorStyle(".ui-theme .bell-header-theme:active","background-color",e)},_updateBellNotificationBackground:function(e){this._updateCssSelectorStyle(".ui-theme .bell-notification-theme","background-color",e),this._updateCssSelectorStyle(".ui-theme .bell-background-theme","background-color",e)},_updateBellNotificationBackgroundHover:function(e){this._updateCssSelectorStyle(".ui-theme .bell-notification-theme:hover","background-color",e),this._updateCssSelectorStyle(".ui-theme .bell-notification-theme:focus","background-color",e)},_updateBellNotificationBackgroundActive:function(e){this._updateCssSelectorStyle(".ui-theme .bell-notification-theme:active","background-color",e)},_updateBellNewNotificationBackground:function(e){this._updateCssSelectorStyle(".ui-theme .bell-notification-theme.new-notification","background-color",e)},_updateBellNewNotificationBackgroundHover:function(e){this._updateCssSelectorStyle(".ui-theme .bell-notification-theme.new-notification:hover","background-color",e),this._updateCssSelectorStyle(".ui-theme .bell-notification-theme.new-notification:focus","background-color",e)},_updateBellNewNotificationBackgroundActive:function(e){this._updateCssSelectorStyle(".ui-theme .bell-notification-theme.new-notification:active","background-color",e)},_updateBellCommentBackground:function(e){this._updateCssSelectorStyle(".ui-theme .bell-comment-theme","background-color",e),this._updateCssSelectorStyle(".unc-container .notifications-widget-light .comment-timeline .comment-container-box .comment-tip::before","background-color",e),this._updateCssSelectorStyle(".unc-container .notifications-widget-light .comment-timeline .comment-container-box .comment-tip::before","border-color",e)},_updateBellButtonBackground:function(e){this._updateCssSelectorStyle(".ui-theme .bell-button-theme","background-color",e)},_updateBellButtonBackgroundHover:function(e){this._updateCssSelectorStyle(".ui-theme .bell-button-theme:hover","background-color",e),this._updateCssSelectorStyle(".ui-theme .bell-button-theme:focus","background-color",e)},_updateBellButtonBackgroundActive:function(e){this._updateCssSelectorStyle(".ui-theme .bell-button-theme:active","background-color",e)},_updateBellBorderColor:function(e){this._updateCssSelectorStyle(".ui-theme .bell-border-theme","border-color",e)},_updateBellThemeText:function(e){this._updateCssSelectorStyle(".ui-theme .bell-theme-text","color",e)},_updateBellThemeTextHover:function(e){this._updateCssSelectorStyle(".ui-theme .notification-container:hover .bell-theme-text","color",e),this._updateCssSelectorStyle(".ui-theme .notification-container:focus .bell-theme-text","color",e)},_updateBellThemeTextNoHover:function(e){this._updateCssSelectorStyle(".ui-theme .bell-theme-text-no-hover","color",e)},_updateBellDarkText:function(e){this._updateCssSelectorStyle(".ui-theme .bell-dark-text","color",e)},_updateBellDarkTextHover:function(e){this._updateCssSelectorStyle(".ui-theme .notification-container:hover .bell-dark-text","color",e),this._updateCssSelectorStyle(".ui-theme .notification-container:focus .bell-dark-text","color",e),this._updateCssSelectorStyle(".ui-theme .notifications-title:hover .bell-dark-text","color",e),this._updateCssSelectorStyle(".ui-theme .notifications-title:focus .bell-dark-text","color",e)},_updateBellDarkTextNoHover:function(e){this._updateCssSelectorStyle(".ui-theme .bell-dark-text-no-hover","color",e)},_updateBellTimestampText:function(e){this._updateCssSelectorStyle(".ui-theme .bell-timestamp-text","color",e)},_updateBellTimestampTextHover:function(e){this._updateCssSelectorStyle(".ui-theme .notification-container:hover .bell-timestamp-text","color",e),this._updateCssSelectorStyle(".ui-theme .notification-container:focus .bell-timestamp-text","color",e)},_updateBellButtonText:function(e){this._updateCssSelectorStyle(".ui-theme .bell-button-text","color",e)},_updateBellButtonTextHover:function(e){this._updateCssSelectorStyle(".ui-theme .cta-button:hover .bell-button-text","color",e),this._updateCssSelectorStyle(".ui-theme .cta-button:focus .bell-button-text","color",e)},_updateBellThumbnailBorderColor:function(e){this._updateCssSelectorStyle(".ui-theme .bell-thumbnail-border-theme","border-color",e)},_updateBellCommentContainerBorderColor:function(e){this._updateCssSelectorStyle(".ui-theme .bell-comment-container-border-theme","-webkit-box-shadow","0 0 0.0625em 0 "+e)},_updateBellScrollbarColor:function(e){this._updateCssSelectorStyle("div.notifications-data-wrapper::-webkit-scrollbar-thumb","background-color",e)},_updateBellShowMoreBackground:function(e){this._updateCssSelectorStyle(".ui-theme .bell-show-more-background","background-color",e)},_updateBellShowMoreBackgroundHover:function(e){this._updateCssSelectorStyle(".ui-theme .bell-show-more-background:hover","background-color",e),this._updateCssSelectorStyle(".ui-theme .bell-show-more-background:focus","background-color",e)},_updateThemeFilePreviewBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-file-preview-background","background-color",e)},_updateThemeFilePreviewHoverBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-file-preview-background:hover","background-color",e)},_updateThemeFilePreviewCheckedBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-file-preview-background.selected","background-color",e),this._updateCssSelectorStyle(".ui-theme .theme-file-preview-background:focus","background-color",e)},_updateThemeFilePreviewCheckedHoverBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-file-preview-background.selected:hover","background-color",e),this._updateCssSelectorStyle(".ui-theme .theme-file-preview-background:focus","background-color",e)},_updateThemeGridViewCheckedBorderColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-grid-view-border.selected","border-color",e),this._updateCssSelectorStyle(".ui-theme .theme-grid-view-border:focus","border-color",e)},_updateBellShowMoreTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .bell-blue-text","color",e)},_updateBellShowMoreTextColorHover:function(e){this._updateCssSelectorStyle(".ui-theme .bell-blue-text:hover","color",e),this._updateCssSelectorStyle(".ui-theme .bell-blue-text:focus","color",e)},_updateBellShowMoreTextColorActive:function(e){this._updateCssSelectorStyle(".ui-theme .bell-blue-text:active","color",e)},_updateFSSButtonBackground:function(e){this._updateCssSelectorStyle(".ui-theme .fss-button-theme","background-color",e)},_updateFSSButtonBackgroundHover:function(e){this._updateCssSelectorStyle(".ui-theme .fss-button-theme:hover","background-color",e)},_updateFSSButtonBackgroundActive:function(e){this._updateCssSelectorStyle(".ui-theme .fss-button-theme:active","background-color",e)},_updateFSSBackground:function(e){this._updateCssSelectorStyle(".ui-theme .fss-background-theme","background-color",e)},_updateFSSHeaderText:function(e){this._updateCssSelectorStyle(".ui-theme .fss-header-text-theme","color",e)},_updateFSSNormalText:function(e){this._updateCssSelectorStyle(".ui-theme .fss-normal-text-theme","color",e)},_updateFSSErrHeader:function(e){this._updateCssSelectorStyle(".ui-theme .fss-err-header-theme","color",e)},_updateFSSHighlight:function(e){this._updateCssSelectorStyle(".ui-theme .fss-highlight-theme","background-color",e)},_updateContextBoardActiveText:function(e){this._updateCssSelectorStyle(".ui-theme .cb-active-text-theme","color",e),this._updateCssSelectorStyle(".ui-theme .drop-down-text-theme","color",e)},_updateContextBoardActiveTextHover:function(e){this._updateCssSelectorStyle(".ui-theme .cb-active-text-theme:hover","color",e),this._updateCssSelectorStyle(".ui-theme .drop-down-text-theme:hover","color",e),this._updateCssSelectorStyle(".ui-theme .drop-down-text-theme:focus","color",e)},_updateContextBoardActiveTextClick:function(e){this._updateCssSelectorStyle(".ui-theme .cb-active-text-theme:active","color",e),this._updateCssSelectorStyle(".ui-theme .cb-active-text-theme.selected","color",e),this._updateCssSelectorStyle(".ui-theme .cb-active-text-theme.focused","color",e),this._updateCssSelectorStyle(".ui-theme .drop-down-text-theme:active","color",e),this._updateCssSelectorStyle(".ui-theme .drop-down-text-theme.selected","color",e),this._updateCssSelectorStyle(".ui-theme .drop-down-text-theme.focused","color",e)},_updateContextBoardHighlightedText:function(e){this._updateCssSelectorStyle(".ui-theme .cb-highlight-text-theme","color",e)},_updateContextBoardShadedText:function(e){this._updateCssSelectorStyle(".ui-theme .cb-shaded-text-theme","color",e)},_updateContextBoardLinkText:function(e){this._updateCssSelectorStyle(".ui-theme .cb-link-text-theme","color",e)},_updateContextBoardLinkTextHover:function(e){this._updateCssSelectorStyle(".ui-theme .cb-link-text-theme:hover","color",e)},_updateContextBoardLinkTextActive:function(e){this._updateCssSelectorStyle(".ui-theme .cb-link-text-theme:active","color",e)},_updateContextBoardText:function(e){this._updateCssSelectorStyle(".ui-theme .cb-text-theme","color",e)},_updatePreviewHudBackground:function(e){this._updateCssSelectorStyle(".ui-theme .preview-hud-background-theme","background-color",e)},_updateContextBoardPlaceholderText:function(e){this._updateCssSelectorStyle(".ui-theme .reminder-note-wrapper textarea::placeholder","color",e),this._updateCssSelectorStyle(".ui-theme .cancel-note-wrapper textarea::placeholder","color",e)},_updateDropdownBackground:function(e){this._updateCssSelectorStyle(".ui-theme .dropdown-background-theme","background-color",e)},_updateDropdownBorder:function(e){this._updateCssSelectorStyle(".ui-theme .dropdown-border-theme","border-color",e)},_updateDropdownTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .dropdown-text-color-theme","color",e)},_updateDropdownHoverTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .dropdown-text-color-theme:hover","color",e)},_updateDropdownSelectedTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .dropdown-text-color-theme.selected","color",e)},_updateDropdownHoverMenuBg:function(e){this._updateCssSelectorStyle(".ui-theme .dropdown-text-bg-color-theme:hover","background-color",e),this._updateCssSelectorStyle(".ui-theme .column-bg-color-theme:hover","background-color",e)},_updateDropdownPressedMenuBg:function(e){this._updateCssSelectorStyle(".ui-theme .dropdown-text-bg-color-theme:active","background-color",e),this._updateCssSelectorStyle(".ui-theme .column-bg-color-theme:active","background-color",e),this._updateCssSelectorStyle(".ui-theme .column-bg-color-theme.selected","background-color",e)},_updateDropdownMenuBg:function(e){this._updateCssSelectorStyle(".ui-theme .dropdown-text-bg-color-theme","background-color",e),this._updateCssSelectorStyle(".ui-theme .column-bg-color-theme","background-color",e)},_updateWorkflowFilesHeaderColumnSortTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .workflow-files-header-column-sort-text-theme","color",e),this._updateCssSelectorStyle(".ui-theme .workflow-files-header-column-no-sort-text-theme","color",e)},_updateWorkflowFilesHeaderColumnSortSelectedTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .workflow-files-header-column-sort-text-theme.selected","color",e)},_updateWorkflowFilesHeaderColumnSortActiveTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .workflow-files-header-column-sort-text-theme:active","color",e)},_updateWorkflowFilesHeaderColumnSortHoverTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .workflow-files-header-column-sort-text-theme:hover","color",e)},_updateFileListThumbnailBorder:function(e){this._updateCssSelectorStyle(".ui-theme .file-list-thumbnail-border","border-color",e)},_updateSharedFileListNormalTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .shared-file-list-text-color","color",e)},_updateSharedFileListActiveTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .shared-file-list-text-color:active","color",e),this._updateCssSelectorStyle(".ui-theme .shared-file-list-text-color:focus","color",e),this._updateCssSelectorStyle(".ui-theme .shared-file-list-text-color.focused","color",e),this._updateCssSelectorStyle(".ui-theme .shared-file-list-text-color.selected","color",e)},_updateSharedFileListHoverTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .shared-file-list-text-color:hover","color",e)},_updateCalendarDayHoverColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-calendar-day:hover","background-color",e)},_updateCalendarDaySelectedColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-calendar-day.selected","background-color",e)},_updateCalendarDaySelectedDateColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-calendar-day.selected","color",e)},_updateCalendarDayMouseDownColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-calendar-day:active","background-color",e)},_updateCalendarDayKeyboardFocusColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-keyboard-focus","color",e)},_updateCalendarDayKeyboardFocusBacgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-keyboard-focus","background-color",e)},_updateSFSTrialBarState1BackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-sfs-trial-bar-state1-color","background-color",e)},_updateSFSTrialBarState2BackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-sfs-trial-bar-state2-color","background-color",e)},_updateSFSTrialBarState3BackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-sfs-trial-bar-state3-color","background-color",e)},_updateSFSModalTrialBarBackgroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-sfs-modal-trial-bar-color","background-color",e)},_updateCopyLinkCopiedTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-copy-link-text","color",e)},_updateToggleTrackBackGroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .toggle-theme .slider","background-color",e)},_updateToggleBarBackGroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .toggle-theme .slider::before","background-color",e)},_updateToggleBarBorderBackGroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .toggle-theme .slider::before","border-color",e)},_updateToggleCheckedTrackBackGroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .toggle-theme input:checked + .slider","background-color",e)},_updateToggleCheckedBarBackGroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .toggle-theme input:checked + .slider::before","background-color",e)},_updateToggleCheckedBarBorderBackGroundColor:function(e){this._updateCssSelectorStyle(".ui-theme .toggle-theme input:checked + .slider::before","border-color",e)},_updateFloatingWindowButtonTextColor:function(e){this._updateCssSelectorStyle(".ui-theme .floating-window-button-text","color",e)},_updateSharePopupBorderColor:function(e){this._updateCssSelectorStyle(".ui-theme .theme-share-popup-border","border-color",e)},_updatePopupQuietButtonColors:function(e,t,n,r){this._updateCssSelectorStyle(".ui-theme .popup-quiet-button","color",r),this._updateCssSelectorStyle(".ui-theme .popup-quiet-button","background-color",e),this._updateCssSelectorStyle(".ui-theme .popup-quiet-button:hover","background-color",t),this._updateCssSelectorStyle(".ui-theme .popup-quiet-button:active","background-color",n),this.isHighContastEnabled&&(this._updateCssSelectorStyle(".ui-theme .popup-quiet-button","border-width","2px"),this._updateCssSelectorStyle(".ui-theme .popup-quiet-button","border-style","solid"),this._updateCssSelectorStyle(".ui-theme .popup-quiet-button","border-color",r))}}),e.ApplyUIThemeStyleOp}),define("app/dev/ops/preferences/restoring-preferences-op",["core/ac-core","app/ac-app","core/utils/cookie-util","core/ops/op"],function(e,t,n){t.RestoringPreferencesOp=e.Op.extend({run:function(){var r=this.options,i=r.preferencesUiModel,s,o,u,a=r.quotaDlgUiModel;try{s=JSON.parse(n.getPersonalCookie(e.Config.PREFERENCES_COOKIE_PREFIX,r.appApi.usersMeApi.getUserIdentity().email)),i.setPreferences(s),o=i.getPreferences(t.APP_ID),u=o.quota,u&&a.set("running_out_shown",u.running_out_shown),r.appApi.pluginsApi.setPreferences(i.getPreferences())}catch(f){}return this._getResolvedPromise()}})}),define("app/dev/ops/preferences/saving-preferences-op",["core/ac-core","app/ac-app","core/utils/cookie-util","core/ops/op"],function(e,t,n){t.SavingPreferencesOp=e.Op.extend({run:function(){var r=this.options,i=$.Deferred(),s=r.preferencesUiModel,o=r.quotaDlgUiModel,u=r.appApi,a,f,l;return u&&(a=u.usersMeApi.getUserIdentity().email),a?(f=s.get("preferences"),l=f[t.APP_ID],l||(l=f[t.APP_ID]={}),l.quota={running_out_shown:o.get("running_out_shown")},l.lastToolUsed=r.toolsUiModel.getSelectedId(),u&&_.extend(f,u.pluginsApi.getPreferences()),n.setPersonalCookie(e.Config.PREFERENCES_COOKIE_PREFIX,a,JSON.stringify(f)),i.resolve().promise()):i.resolve().promise()}})}),define("app/dev/ops/rna/configuring-rna-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){return t.ConfiguringRNAOp=e.Op.extend({run:function(){var e=this.options,t=e.appApi;return this._getResolvedPromise()}}),t.ConfiguringRNAOp}),define("app/dev/ops/rna/initializing-rna-op",["core/ac-core","app/ac-app","core/utils/date-util","core/ops/op"],function(e,t,n){return t.InitializingRNAOp=e.Op.extend({run:function(){var t=this.options,r=t.appApi,i=e.opFactory,s,o;return s=i.create("InitializingCEFOp",t),o=i.create("InitializingReaderOp",t),n.logElapsedTime("before CreatingBrowserContext"),s.run().then(_.bind(function(){n.logElapsedTime("after CreatingBrowserContext"),o.run()},this))}}),t.InitializingRNAOp}),define("app/dev/ops/rna/listening-for-dialog-alert-events-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){return t.ListeningForDialogAlertEventsOp=e.Op.extend({run:function(){var e=this.options.dialogsUiModel;return e.on("change:open",this._onDialogCountChange),this._getResolvedPromise()},_onDialogCountChange:function(e){this.options.appApi.rnaApi.done(_.bind(function(t){e.length>0?t.rnaServicesAPI.setCanHandleCEFEvent(0,!0):t.rnaServicesAPI.setCanHandleCEFEvent(0,!1)},this))}}),t.ListeningForDialogAlertEventsOp}),define("app/dev/ops/rna/listening-for-notification-window-events-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){t.ListeningForNotificationWindowEventsOp=e.Op.extend({initialize:function(){e.Op.prototype.initialize.call(this)},run:function(){return this.$notificationContainer=$(".notification-content-container"),setInterval(_.bind(function(){this._handleResize()},this),250),this._handleResize(),(this._deferred=$.Deferred()).promise()},_handleResize:function(){var e,t;this.$notificationContainer.length===0&&(this.$notificationContainer=$(".notification-content-container"));if(this.$notificationContainer.length){e=this.$notificationContainer.width(),t=this.$notificationContainer.outerHeight();if(this._oldWidth!==e||this._oldHeight!==t)this._oldWidth=e,this._oldHeight=t,this.options.appApi.rnaApi.done(function(n){n.cefBrowserApi({methodName:"setContainerSize",parameters:[e,t]})})}}})}),define("app/dev/ops/rna/listening-for-rhp-window-events-op",["core/ac-core","app/ac-app","core/utils/css-util","core/ops/op"],function(e,t,n){t.ListeningForRHPWindowEventsOp=e.Op.extend({initialize:function(){e.Op.prototype.initialize.call(this)},run:function(){return this.$rhpContainer=$(".rhp-container-content"),this.$alertDialogContainer=$(".generic-dialog-rhp"),setInterval(_.bind(function(){this._handleResize()},this),250),this._handleResize(),(this._deferred=$.Deferred()).promise()},_handleResize:function(){var e,t;this.$rhpContainer.length===0&&(this.$rhpContainer=$(".rhp-container-content")),this.$alertDialogContainer&&this.$alertDialogContainer.length===0&&(this.$alertDialogContainer=$(".generic-dialog-rhp")),e=this.$rhpContainer.width(),t=this.$rhpContainer.height(),this.$alertDialogContainer&&this.$alertDialogContainer.length>0&&t0?t.split("-")[0]:n.UNKNOWN}),Ac.currentRNAVariants&&_.each(Ac.currentRNAVariants,function(e,i){var s=t.pluginsApi.getSiteCatalystName(i,i,!0);r([n.WEB_PLUGIN_VARIANT,s,e])}),this._getResolvedPromise()}}),t.InitializingScLoggingOp}),define("app/dev/ops/routing/rna-routing-at-content-page-op",["core/ac-core","files/ac-files","app/ac-app","plugins-common/ac-plugins","core/utils/app-api-mgr","core/utils/date-util","core/utils/view-util","core/ops/op"],function(e,t,n,r,i,s,o){return n.RNARoutingAtContentPageOp=e.Op.extend({run:function(r,u){function M(){return Ac.Plugins.types.tools.default_plugin_id}function _(){return Ac.Plugins.types.full_preview.default_plugin_id}function D(){d.run(),A.run().always(function(){g.run()}),o.init(a);if(a.toolsUiModel.get("pending_plugin_id"))return n.viewMgr.showContentPageView(a),k;if(a.runningInRHP&&n.viewMgr.isContentPageViewUnset())return n.viewMgr.showContentPageView(a),w.run(_());if(a.runningInFull)return n.viewMgr.showContentPageView(a),p.run(M());if(a.runningInFileSelection&&n.viewMgr.isContentPageViewUnset())return T.run();if(a.runningInNotification&&n.viewMgr.isContentPageViewUnset())return n.viewMgr.showContentPageView(a),k;if(a.runningInWhatsNewView&&n.viewMgr.isContentPageViewUnset())return C.run()}var a=this.options,f=a.appApi,l,c,h,p,d,v,m,g,y,b,w,E,S,x,T,N,C,k=this._getResolvedPromise(),L,A,O;s.logElapsedTime("routing-at-content-page-op start"),l=e.opFactory,c=n.opFactory,h=t.opFactory,d=c.create("ShowingLoadFailuresDlgOp",a),E=c.create("GettingAllBaseUrisOp",a),v=c.create("GettingStorageInfoOp",a),m=c.create("GettingAllUserInfoOp",a),g=c.create("InitializingScLoggingOp",a),S=l.create("StartingSusiSessionOp",a),x=c.create("LoadingTemplatePluginsOp",a),y=c.create("LoadingToolsOp",a),p=c.create("SelectingToolOp",a),b=h.create("LoadingFullPreviewPluginsOp",a),w=h.create("SelectingFullPreviewPluginOp",a),T=c.create("LoadingFileSelectionDlgOp",a),N=c.create("LoadingFileSelectionDlgHomeViewsOp",a),C=c.create("LoadingWhatsNewDlgOp",a),L=c.create("LoadingRNAVersionInfoOp",a),A=c.create("LoadingRNAVariantInfoOp",a),O=l.create("GettingDocumentCloudStorageInfoOp",a);if(!r)return s.logElapsedTime("before base uris + plugin configs"),$.when(S.run(),E.run(),L.run()).then(function(){return f.pluginsApi.validateRNAPlugin(u).then(function(){return s.logElapsedTime("after starting susi"),O.run().then(function(){return $.when(v.run(),m.run()).then(function(){a.signInUiModel.set("is_signed_in",!0)})},function(e){return(e.errorString==="NoAccessToPdfServices"||e.errorString==="DCAPIUnsupported-Error410")&&a.signInUiModel.set("is_signed_in",!0),$.Deferred().reject(e).promise()})})});i.appApisAreReady();if(a.runningInRHP)return b.run().then(function(){return D()});if(a.runningInFull)return x.run().then(function(){if(a.runningInFull)return y.run().then(function(){return D()})});if(a.runningInFileSelection)return x.run().then(function(){return e.opFactory.create("GettingConnectorsUiHelpersOp",a).run(),e.opFactory.create("GettingSystemFoldersOp",a).run(),D()});if(a.runningInNotification)return D();if(a.runningInWhatsNewView)return x.run().then(function(){return D()})}}),n.RNARoutingAtContentPageOp}),define("app/dev/ops/routing/routing-at-content-page-op",["core/ac-core","app/ac-app","plugins-common/ac-plugins","core/utils/app-api-mgr","core/utils/date-util","core/utils/ipm-util","core/ops/op"],function(e,t,n,r,i,s){return t.RoutingAtContentPageOp=e.Op.extend({run:function(){function h(){var e=u.getSubscriptionName(),t;switch(e){case u.SUBSCRIPTION_ACROBATPLUS:case u.SUBSCRIPTION_ACROBATSTD:t=n.ACROBAT;break;case u.SUBSCRIPTION_CREATEPDF:case u.SUBSCRIPTION_PDFPACK:t=n.CONVERTPDF;break;case u.SUBSCRIPTION_EXPORTPDF:t=n.EXPORTPDF;break;case u.SUBSCRIPTION_FILES:t=n.HOME;break;case u.SUBSCRIPTION_FILLANDSIGN:t=n.FILLSIGN;break;case u.SUBSCRIPTION_FORMSCENTRAL:t=n.FORMSCENTRAL;break;case u.SUBSCRIPTION_SENDNOW:t=n.SEND}return t}var e=this.options,o=e.appApi,u=o.usersMeApi,a=o.pluginsApi,f,l,c;return i.logElapsedTime("routing-at-content-page-op start"),l=t.opFactory,c=l.create("SelectingToolOp",e),r.appApisAreReady(),e.toolsUiModel.get("pending_plugin_id")?this._getResolvedPromise():(f=u.getCommonUserPrefs(),c.run(a.getEnabledPlugin(f.lastToolUsed)||s.getMarketingTool()||a.getEnabledPlugin(h())))}}),t.RoutingAtContentPageOp}),define("app/dev/ops/session/handling-401-error-op",["core/ac-core","app/ac-app","core/utils/http-util","core/utils/util","core/ops/op"],function(e,t,n,r){var i;t.Handling401ErrorOp=e.Op.extend({run:function(e){var t=this.options,s=t.appApi,o=this._getResolvedPromise();return t.acrobatUiModel.get("is_in_acrobat")?o:(r.isCEF()&&s.usersMeApi.clearUserInfo(),t.signInUiModel.set("is_signed_in",!1),i||(n.clearSessionAttrs(t.sessionUiModel),r.isCEF()?e||(o=s.sessionApi.ensureSignedIn().then(function(){i=!1}),i=!0):(s.routerApi.reloadPage({reason:"401"}),i=!0)),o)}})}),define("app/dev/ops/session/signing-in-from-error-op",["core/ac-core","app/ac-app","core/utils/util","core/ops/op"],function(e,t,n){t.SigningInFromErrorOp=e.Op.extend({run:function(){var e=this.options;return e.errorUiModel.clearQueue(),n.isCEF()?this._getResolvedPromise():t.opFactory.create("SigningOutOp",e).run()}})}),define("app/dev/ops/session/signing-out-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){t.SigningOutOp=e.Op.extend({run:function(){var t=this.options,n=t.appApi.displayApi;return n.showModal(!0),n.showSpinner(!0),e.opFactory.create("StoppingSessionOp",t).run().then(function(e){window.location=e.uri})}})}),define("app/dev/ops/settings-dlg/loading-settings-dlg-views-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){return t.LoadingSettingsDlgViewsOp=e.Op.extend({run:function(){var t=this.options,n=t.appApi.pluginsApi;return e.opFactory.create("LoadingPluginsOp",_.extend({pluginsConfig:n.getPluginTypeConfig("settings_dlg"),pluginsUiModel:t.settingsDlgUiModel},_.pick(t,"appApi","pluginId","force"))).run()}}),t.LoadingSettingsDlgViewsOp}),define("app/dev/ops/settings-dlg/selecting-settings-dlg-plugin-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){return t.SelectingSettingsDlgPluginOp=e.Op.extend({run:function(t){return e.opFactory.create("SelectingPluginOp",this.options).run(t)}}),t.SelectingSettingsDlgPluginOp}),define("app/dev/templates/settings-dlg-template",[],function(){return''}),define("app/dev/templates/settings-dlg-selector-template",[],function(){return'
<%= label %>
'}),define("app/dev/views/settings-dlg-selector-view",["core/ac-core","app/ac-app","app/templates/settings-dlg-selector-template","core/views/plugins-selector-view","app/views/view-events"],function(e,t,n){t.SettingsDlgSelectorView=e.PluginsSelectorView.extend({initialize:function(){e.PluginsSelectorView.prototype.initialize.call(this)},_getSelectorTemplate:function(){return n},_getSelectorViewEvent:function(){return t.ViewEvents.SETTINGS_DLG_SELECTOR_CLICK}})}),define("app/dev/templates/settings-dlg-content-template",[],function(){return'
'}),define("app/dev/views/settings-dlg-content-view",["core/ac-core","app/ac-app","app/templates/settings-dlg-content-template","core/views/plugins-content-view"],function(e,t,n){t.SettingsDlgContentView=e.PluginsContentView.extend({_getContentTemplate:function(){return n}})}),define("app/dev/views/settings-dlg-view",["core/ac-core","app/ac-app","core/utils/util","app/templates/settings-dlg-template","i18n!core/nls/ui-strings","core/utils/sc-analytics","core/views/dialog-view","app/views/settings-dlg-selector-view","app/views/settings-dlg-content-view"],function(e,t,n,r,i,s){t.SettingsDlgView=e.DialogView.extend({events:function(){return _.extend({},e.DialogView.prototype.events,{"click .settings-dlg-done-btn":"_onDoneClick"})},initialize:function(){e.DialogView.prototype.initialize.call(this),this._setParentScContext(this.options.scContext)},render:function(){return e.DialogView.prototype.render.call(this,!1),this.$el.empty().html(_.template(r)({title:this._getTitle(),done:i.DONE})),this._initWrappers(),n.isCEF()&&this.$dlg.addClass("cef"),this._center(),this.$dlg.addClass("shown"),this._renderChildViews(),this},open:function(n){var r,i=this.options,s=i.appApi.pluginsApi,o;return this._pluginOptions=n,o=t.opFactory.create("LoadingSettingsDlgViewsOp",i),o.run().then(_.bind(function(){return s.callPluginMethodForEach(s.getPluginTypeConfig("settings_dlg").plugin_ids,"setPluginOptions",n,undefined,!0),r=e.DialogView.prototype.open.call(this),this._selectPlugin(undefined,n),r},this))},close:function(t,n){var r=this.$dlg,i;delete this._pluginOptions,i=_.bind(function(){e.DialogView.prototype.close.call(this,t,n)},this),r.removeClass("shown"),i()},_onViewEvent:function(e,n){var r=t.ViewEvents;if(e===r.SETTINGS_DLG_SELECTOR_CLICK)return this._selectPlugin(n);this.trigger(e,n)},_initWrappers:function(){e.DialogView.prototype._initWrappers.call(this),this.$selector=this.$(".views-selector"),this.$content=this.$(".settings-dlg-plugin-content")},_renderChildViews:function(){var e=_.extend({},this.options,{pluginsUiModel:this.options.settingsDlgUiModel});this._renderChildView("_contentView",t.SettingsDlgContentView,this.$content,e),this._renderChildView("_selectorView",t.SettingsDlgSelectorView,this.$selector,e)},_getTitle:function(){return i.SETTINGS},_selectPlugin:function(e){var n,r=this._pluginOptions;return e||(e=this.options,n=e.settingsDlgUiModel.getSelectedId()||e.appApi.pluginsApi.getPluginTypeConfig("settings_dlg").default_plugin_id,this._logSiteCatalystEvent([s.SHOWN]),e=_.extend({},e,{pluginId:n})),r=r||{},r.scContext=this._getFullScContext(),t.opFactory.create("SelectingSettingsDlgPluginOp",e||this.options).run(r).then(_.bind(function(){return undefined},this))},_onDoneClick:function(){this._logSiteCatalystEvent([s.COMPLETED]),this.close(!0);var e=this.options.settingsDlgUiModel;e.trigger("change:faf-done-button-clicked")}})}),define("app/dev/ops/settings-dlg/showing-settings-dlg-op",["core/ac-core","app/ac-app","core/ops/op","app/views/settings-dlg-view"],function(e,t){return t.ShowingSettingsDlgOp=e.Op.extend({run:function(){return(new t.SettingsDlgView(this.options)).open()}}),t.ShowingSettingsDlgOp}),define("app/dev/ops/site-catalyst/get-framework-pages-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){t.GetFrameworkPagesOp=e.Op.extend({run:function(){var e={Term:{kind:"value",values:["Monthly","AnnualBilledMonthly","AnnualBilledAnnually","None"]},FileList:{kind:"value",values:["DOCCLD:FileList","CCLOUD:FileList","ONEDRV:FileList","RecentFiles"]},Connector:{kind:"value",values:["DOCCLD","CCLOUD","ONEDRV"]},BusinessSource:{kind:"value",values:["Dell","AcPr","CCM","Tril","None","TEAM"]},PreviewType:{kind:"value",values:["Preview","Preview:NGDoc"]},CountValue2:{kind:"value",values:["2to5","6to10","11orMore"]},CountValue1:{kind:"value",values:["1","2to5","6to10","11orMore"]},CountValue0:{kind:"value",values:["0","1","2to5","6to10","11orMore"]}},t=[{pageName:"free:InitialStartup",selector:""},{pageName:"adobe.com:products:eula:third_party",selector:""},{pageName:"InitialStartup",selector:""},{pageName:"InitialStartup:FirstTimeUser",selector:""},{pageName:"InitialStartup:ReturningUser",selector:""},{pageName:"ABTEST::",selector:""},{pageName:"ChatPod:Expanded",selector:""},{pageName:"ChatPod:Shrunk",selector:""},{pageName:"ChatPod:Hidden",selector:""},{pageName:"ChatPod:Entered",selector:""},{pageName:"ChatPod:Left",selector:""},{pageName:"ChatPod:Sent",selector:""},{pageName:"ABTest:Control:CHAT_POD_TEST",selector:""},{pageName:"ABTest:Var1:CHAT_POD_TEST",selector:""},{pageName:"ABTest:Var2:CHAT_POD_TEST",selector:""},{pageName:"General:Error:400",selector:""},{pageName:"General:Error:401",selector:""},{pageName:"General:Error:403:Forbidden:FolderNotEmpty",selector:""},{pageName:"General:Error:403:Forbidden:QuotaExceeded",selector:""},{pageName:"General:Error:403:Forbidden:VirusDetected",selector:""},{pageName:"General:Error:403:Generic",selector:""},{pageName:"General:Error:404:NotFound",selector:""},{pageName:"General:Error:405",selector:""},{pageName:"General:Error:406",selector:""},{pageName:"General:Error:412",selector:""},{pageName:"General:Error:415",selector:""},{pageName:"General:Error:500",selector:""},{pageName:"General:Error:501",selector:""},{pageName:"General:Error:503",selector:""},{pageName:"General:Error:504",selector:""},{pageName:"SignIn:Shown",selector:""},{pageName:"TopHeader:AcomTrefoil:Clicked",selector:""},{pageName:"TopHeader:Acrobat.com:Clicked",selector:""},{pageName:"TopHeader:Apps:Clicked",selector:""},{pageName:"TopHeader:AppsMenu:Shown",selector:""},{pageName:"TopHeader:Help:Clicked",selector:""},{pageName:"TopHeader:HelpMenu:Shown",selector:""},{pageName:"TopHeader:UserAcctMenu:Clicked",selector:""},{pageName:"TopHeader:UserAcctMenu:Shown",selector:""},{pageName:"TopHeader:UserAcctMenu:MyInformation",selector:""},{pageName:"TopHeader:UserAcctMenu:Language",selector:""},{pageName:"TopHeader:UserAcctMenu:MyPlan",selector:""},{pageName:"TopHeader:UserAcctMenu:SignOut",selector:""},{pageName:"TopHeader:UserAcctMenu:StorageLearnMore:Clicked",selector:""},{pageName:"TopHeader:HelpMenu:AskUs",selector:""},{pageName:"TopHeader:HelpMenu:AboutProduct",selector:""},{pageName:"TopHeader:HelpMenu:ProductHelp",selector:""},{pageName:"TopHeader:User:acctMenu:SettingsDlg",selector:""},{pageName:"Tools:Files:Clicked",selector:""},{pageName:"Toolbar:AddFiles:Clicked",selector:""},{pageName:":SmallPreview:Shown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SmallPreview:NextPg",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SmallPreview:PrevPg",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":InitialView:NumFilesShown:",selector:"",variables:{FileList:e.FileList,CountValue0:e.CountValue0},values:e.CountValue0},{pageName:":InitialView:NumFoldersShown:",selector:"",variables:{FileList:e.FileList,CountValue0:e.CountValue0},values:e.CountValue0},{pageName:"FileList:AllFiles:Clicked",selector:""},{pageName:":NewFolderIcon:Clicked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":NewFolderDlg:Shown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":NewFolderDlg:Success",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":NewFolderDlg:Cancel",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":NewFolderDlg:Error:FolderExists",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":UploadIcon:Clicked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":Empty:UploadIcon:Clicked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":Upload:NumFiles:",selector:"",variables:{FileList:e.FileList,CountValue1:e.CountValue1},values:e.CountValue1},{pageName:":Upload:Success",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:"FileList:RecentFiles:Clicked",selector:""},{pageName:"::Clicked",selector:"",variables:{FileList:e.FileList,Connector:e.Connector},values:e.Connector},{pageName:":IPM:Clicked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":DupFileNameDlg:Shown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":DupFileNameDlg:Existing",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":DupFileNameDlg:Uploaded",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":DupFileNameDlg:Rename",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":DupFileNameDlg:Continue",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":DupFileNameDlg:DeleteExisting:Success",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":DupFileNameDlg:DeleteUploaded:Success",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":DupFileNameDlg:RenameFile:Success",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":DupFileNameDlg:RenameFile:Cancel",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":DupFileNameDlg:RenameFile:Error:FileExists",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":DupFileNameDlg:Cancel",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":DupFileNameDlg:Cancel",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Clicked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Keyword:Cleared",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Keywords:Dismissed",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:SearchTextEntered",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Results:",selector:"",variables:{FileList:e.FileList,CountValue1:e.CountValue1},values:e.CountValue1},{pageName:":SearchBar:Results:Success",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:FilterIcon:Clicked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:Shown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:NameContains",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:Name:Entered",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:DateAddedIs",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:Date:Entered",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:DateModifiedIs",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:DateModified:Entered",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:FileType:Excel",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:FileType:HTML",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:FileType:Image",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:FileType:InDesign",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:FileType:PDF",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:FileType:Photoshop",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:FileType:Powerpoint",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:FileType:Text",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:FileType:Video",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:FileType:Zip",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:FileType:Word",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:IsShared",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:FileLocation",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:CreatedByTool:ExportPDF",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:CreatedByTool:CreatePDF",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:CreatedByTool:Combine",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:CreatedByTool:ReaderMobile",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:CreatedByTool:Reader",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Filter:CreatedByTool:Acrobat",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:SortIcon:Clicked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:Sort:Shown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:ViewBy:List:Checked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:ViewBy:Thumb:Checked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:SortBy:FileNameDown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:SortBy:FileNameUp",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:SortBy:FileTypeDown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:SortBy:FileTypeUp",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:SortBy:FileSizeUp",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:SortBy:FileSizeDown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:SortBy:DateAddedUp",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:SortBy:DateAddedDown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:SortBy:DateModifiedDown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SearchBar:SortBy:DateModifiedUp",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SortColumn:NameUp",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SortColumn:NameDown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SortColumn:SizeUp",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SortColumn:SizeDown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SortColumn:DateUp",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":SortColumn:DateDown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":FileName:Checked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":FileName:Unchecked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":NumFilesChecked:",selector:"",variables:{FileList:e.FileList,CountValue1:e.CountValue1},values:e.CountValue1},{pageName:":ActionBar:Shown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:Cancel:Clicked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":FolderName:Checked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":FolderName:Unchecked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":NumFoldersChecked:",selector:"",variables:{FileList:e.FileList,CountValue1:e.CountValue1},values:e.CountValue1},{pageName:":ActionBar:Rename:Clicked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:RenameDlg:Shown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:RenameDlg:NameEntered",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:RenameDlg:Cancel",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:RenameDlg:Cancel",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:RenameDlg:Success",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:RenameDlg:Error:FileExists",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:RenameDlg:Error:FolderExists",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:Move:Clicked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:MoveDlg:Shown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:MoveDlg:Cancel",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:MoveDlg:Success",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:Download:Clicked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:Download:Success",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:Share:Clicked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:Delete:Clicked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:DeleteDlg:Shown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:DeleteDlg:Cancel",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:DeleteDlg:Success",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:Delete:Error:FolderNotEmpty:Op",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:Delete:ErrorDlg:Shown",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":ActionBar:Delete:ErrorDlg:Cancel",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:":DownloadLink:Clicked",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":Toolbar:GearIcon:Clicked",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":Toolbar:GearMenu:Shown",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":Toolbar:DownloadIcon:Clicked",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":Toolbar:Download:Success",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":Toolbar:GearMenu:Rename:Clicked",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":Toolbar:GearMenu:RenameDlg:Shown",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":Toolbar:GearMenu:RenameDlg:NameEntered",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":Toolbar:GearMenu:RenameDlg:Cancel",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":Toolbar:GearMenu:RenameDlg:Success",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":Toolbar:GearMenu:Delete:Clicked",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":Toolbar:GearMenu:DeleteDlg:Shown",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":Toolbar:GearMenu:DeleteDlg:Cancel",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":Toolbar:GearMenu:DeleteDlg:Success",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":Toolbar:GearMenu:Share:Clicked",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":PDF:Shown",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":NonPDF:Shown",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":PDF:Failed",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":NonPDF:Failed",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:"Preview:Shared:Multi:Preview:Shown",selector:""},{pageName:"Preview:Shared:Multi:Preview:Toolbar:FileInfo",selector:""},{pageName:"Preview:Shared:Multi:Preview:Toolbar:ShareIcon",selector:""},{pageName:"Preview:Shared:Multi:Preview:Toolbar:Back",selector:""},{pageName:"Preview:Shared:Single:Preview:Shown",selector:""},{pageName:"Preview:Shared:Single:Preview:Toolbar:FileInfo",selector:""},{pageName:"Preview:Shared:Single:Preview:Toolbar:ShareIcon",selector:""},{pageName:"Preview:Shared:Single:Preview:RHP:ShareFileButton",selector:""},{pageName:"Preview:Private:Single:Toolbar:FileInfo",selector:""},{pageName:"Preview:Private:Single:Toolbar:ShareIcon",selector:""},{pageName:"Preview:Private:Single:RHP:Share:PublicLink",selector:""},{pageName:"Preview:Private:Single:RHP:Share:PersonalLink",selector:""},{pageName:"Preview:Private:Single:RHP:Subject:Entered",selector:""},{pageName:"Preview:Private:Single:RHP:Message:Entered",selector:""},{pageName:"Preview:Private:Single:RHP:Subject:Default",selector:""},{pageName:"Preview:Private:Single:RHP:Message:Default",selector:""},{pageName:"Preview:Private:Single:RHP:ShareButton",selector:""},{pageName:"Preview:Private:Single:RHP:CancelButton",selector:""},{pageName:"Preview:Private:Single:CommentPane:Shown",selector:""},{pageName:"RecView:Preview:BottomNavBar:ShowRHP",selector:""},{pageName:"RecView:Multi:Preview:IPM",selector:""},{pageName:"RecView:Multi:Preview:SavetoAcrobat",selector:""},{pageName:"RecView:Single:IPM",selector:""},{pageName:"RecView:Single:SavetoAcrobat",selector:""},{pageName:":Shown",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":BottomNavBar:FitPgFull",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":BottomNavBar:FitPgWidth",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":BottomNavBar:FullScreen",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":BottomNavBar:ShowRHP",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":BottomNavBar:HideRHP",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":BottomNavBar:NextPg",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":BottomNavBar:PrevPg",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":BottomNavBar:Scroll",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":BottomNavBar:Close",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":BottomNavBar:PgNumEntered",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":BottomNavBar:ShowImagePreview",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":BottomNavBar:ShowNGDocPreview",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":BottomNavBar:ZoomIn",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":BottomNavBar:ZoomOut",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":Toolbar:FileInfo:Clicked",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:":Toolbar:Back:Clicked",selector:"",variables:{PreviewType:e.PreviewType},values:e.PreviewType},{pageName:"Tools:Share:ChooseFilesDlg:RecFiles:Shown",selector:""},{pageName:"Tools:Share:ChooseFilesDlg:RecFiles:ChooseFiles:Clicked",selector:""},{pageName:"Tools:Share:ChooseFilesDlg:RecFiles:AddSelected:",selector:"",variables:{CountValue1:e.CountValue1},values:e.CountValue1},{pageName:"Tools:Share:ChooseFilesDlg:RecFiles:Cancel",selector:""},{pageName:"Tools:Share:ChooseFilesDlg:SentFiles:Shown",selector:""},{pageName:"Tools:Share:ChooseFilesDlg:SentFiles:ChooseFiles:Clicked",selector:""},{pageName:"Tools:Share:ChooseFilesDlg:SentFiles:AddSelected:",selector:"",variables:{CountValue1:e.CountValue1},values:e.CountValue1},{pageName:"Tools:Share:ChooseFilesDlg:SentFiles:Cancel",selector:""},{pageName:"ProgressStatusMenu:Shown",selector:""},{pageName:"ProgressStatusMenu:Hidden",selector:""},{pageName:"ProgressStatusMenu:RemoveHistory:Clicked",selector:""},{pageName:"Tools:ExportPDF:Clicked",selector:""},{pageName:":ActionBar:ExportPDF:Clicked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:"Tools:CreatePDF:Clicked",selector:""},{pageName:":ActionBar:CreatePDF:Clicked",selector:"",variables:{FileList:e.FileList},values:e.FileList},{pageName:"Tools:Combine:Clicked",selector:""},{pageName:"Tools:Organize:Clicked",selector:""},{pageName:"Tools:Acrobat:Clicked",selector:""},{pageName:"Tools:CreateForm:Clicked",selector:""},{pageName:"Tools:SettingsDlg:InitialView:",selector:""},{pageName:"Tools:SettingsDlg:Close:",selector:""},{pageName:"Tools:SettingsDlg:Cancel",selector:""},{pageName:"BusinessSource:",selector:"##aic-business-source",variables:{BusinessSource:e.BusinessSource},values:e.BusinessSource},{pageName:"BillingTerm:",selector:"##aic-subscription-term",variables:{Term:e.Term},values:e.Term},{pageName:"Tools:SendforSig:Clicked",selector:""}];return $.Deferred().resolve({variables:e,pages:t}).promise()}})}),define("app/dev/ops/site-catalyst/register-page-names-op",["core/ac-core","app/ac-app","core/utils/sc-analytics","core/ops/op"],function(e,t,n){var r=function(e,t,n,r){var i,s;return _.each(t,function(o,u){i=o.replace(/<|>/g,"");if(o.length-i.length!==2)return;(!e.variables||!e.variables[i])&&LOG("Missing site-catalyst variable: "+i,LOG.ERROR,{logServer:!0}),e.variables[i].kind==="value"?s=r&&r.value:s=n.data(i),s||LOG("Missing site-catalyst value for:"+i+" page: "+e.pageName+" selector: "+e.selector,LOG.ERROR,{logServer:!0}),t[u]=s}),t},i=function(e,t,n){var i=r(e,e.pageName.split(":"),t,n),s;return e.prop48&&(s={rawProperties:{}},s.rawProperties.prop48=r(e,e.prop48.split(":"),t,n)),e.prop49&&(s={rawProperties:{}},s.rawProperties.prop49=r(e,e.prop49.split(":"),t,n)),{page:i,options:s}},s=function(e,t,n,r){var s=i(t,n,r);e.logScEvent(s.page,s.options)},o=function(e){var t=$(e.currentTarget);_.find(this.eventStore.clickEvents,function(e){if(t.is(e.selector))return s(this.scApi,e,t),!0},this)},u=function(e){var t=$(e.currentTarget),n;if(!t.is(":visible"))return;if(e.currentTarget!==e.target)return;n=_.find(this.eventStore.renderEvents,function(e){if(t.is(e.selector))return!0},this),n&&s(this.scApi,n,t)},a=function(e){var t=$(e.currentTarget);if(e.currentTarget!==e.target)return;_.find(this.eventStore.dialogSuccessEvents,function(e){if(t.is(e.selector))return s(this.scApi,e,t),!0},this)},f=function(e){var t=$(e.currentTarget);if(e.currentTarget!==e.target)return;_.find(this.eventStore.dialogCancelEvents,function(e){if(t.is(e.selector))return s(this.scApi,e,t),!0},this)},l=function(e){var t=$(e.currentTarget);if(e.currentTarget!==e.target)return;_.find(this.eventStore.dialogValueEvents,function(e){var n;if(t.is(e.selector))return n=this.util.getValue(t),n!==null&&s(this.scApi,e,t,{value:n}),!0},this)},c=function(e){if(e.currentTarget!==e.target)return;var t=$(e.currentTarget),n,r;n=_.find(this.eventStore.dialogChangeEvents,function(e){if(t.is(e.selector))return!0},this),n&&(r=this.util.getValue(t),e.type===this.scApi.RENDER?n.dialogValue=r:r!==n.dialogValue&&s(this.scApi,n,t,{value:r}))},h=function(e,t){if(e.currentTarget!==e.target)return;var n,r=$(e.currentTarget),i=_.find(this.eventStore.countEvents,function(e){if(r.is(e.selector))return!0},this);i&&(n=this.util.getCountCode(t),s(this.scApi,i,r,{value:n}))},p=function(e){if(e.currentTarget!==e.target)return;var t=$(e.currentTarget);_.each(this.eventStore.changeEvents,function(n){if(t.is(n.selector)){var r,i=t.attr("type")==="checkbox",o;i?(r=_.last(n.pageName.split(":")),o=$(e.currentTarget).attr("checked")?"checked":"unchecked",r.toLowerCase()===o&&s(this.scApi,n,t)):s(this.scApi,n,t)}},this)};t.RegisterPageNamesOp=e.Op.extend({run:function(e,t,r,i,s){var d=s.ANALYTICS_SELECTOR,v=r,m=/:Change($|:)/;return _.isEmpty(r)&&(_.extend(r,{scApi:s,util:n,eventStore:i,changeHndlr:p,clickHndlr:o,countFileHndlr:h,dialogCancelHndlr:f,dialogChangeHndlr:c,dialogSuccessHndlr:a,dialogValueHndlr:l,renderHndlr:u}),_.bindAll(r,"renderHndlr","dialogChangeHndlr","dialogCancelHndlr","countFileHndlr","changeHndlr","clickHndlr","dialogValueHndlr","dialogSuccessHndlr"),$("body").on(s.RENDER,d,v.dialogChangeHndlr),$("body").on(s.DIALOG_COMMIT,d,v.dialogChangeHndlr),$("body").on(s.CHANGE,d,v.changeHndlr),$("body").on(s.CLICK,d,v.clickHndlr),$("body").on(s.COUNT_FILES,d,v.countFileHndlr),$("body").on(s.DIALOG_CANCEL,d,v.dialogCancelHndlr),$("body").on(s.RENDER,d,v.renderHndlr),$("body").on(s.DIALOG_COMMIT,d,v.dialogValueHndlr),$("body").on(s.DIALOG_COMMIT,d,v.dialogSuccessHndlr)),e+=".",_.each(t.pages,function(e){if(e.selector.indexOf("##")===0){i.nonUIEvents[e.selector]=e;return}if(!e.selector||e.selector.length===0)return;var t=_.last(e.pageName.split(":")).toLowerCase();m.test(e.pageName)&&e.values?i.dialogChangeEvents.push(e):t.indexOf("countvalue")!==-1?i.countEvents.push(e):e.values?i.dialogValueEvents.push(e):t==="clicked"?i.clickEvents.push(e):t==="shown"?i.renderEvents.push(e):t==="success"?i.dialogSuccessEvents.push(e):t==="cancel"?i.dialogCancelEvents.push(e):t==="checked"||t==="unchecked"?i.changeEvents.push(e):m.test(e.pageName)&&i.changeEvents.push(e)},this),this._getResolvedPromise()}})}),define("app/dev/ops/tools/loading-tools-op",["core/ac-core","app/ac-app","core/utils/util","core/ops/op"],function(e,t,n){t.LoadingToolsOp=e.Op.extend({run:function(){var t=this.options,r=t.appApi.pluginsApi,i;return n.isCEF()&&(i={readerContextModel:t.readerContextModel}),e.opFactory.create("LoadingPluginsOp",_.extend({pluginsConfig:r.getPluginTypeConfig("tools"),pluginsUiModel:t.toolsUiModel,pluginContext:i},_.pick(t,"appApi","pluginId","force"))).run()}})}),define("app/dev/ops/tools/selecting-tool-op",["core/ac-core","app/ac-app","plugins-common/ac-plugins","core/ops/op"],function(e,t,n){t.SelectingToolOp=e.Op.extend({run:function(t){function l(){return t!==s.getCommonUserPrefs().lastToolUsed?s.saveCommonPrefs():$.Deferred().resolve().promise()}var r=this.options,i=r.appApi,s=i.usersMeApi,o=r.toolsUiModel,u,a,f;u=o.get("selected_plugin_id"),a=t||r.pluginId;if(a&&a===u)return this._getResolvedPromise();if(!a||!o.get("plugins").get(a))a=o.getSelectedId();return u!==n.HOME&&i.selectionApi.clearSelection(),f=e.opFactory.create("SelectingPluginOp",_.extend({},r,{pluginId:a})),f.run().then(function(){return l()},function(){return f=e.opFactory.create("SelectingPluginOp",_.extend({},r,{pluginId:o.getFirstEnabledId()})),f.run().then(function(){return l()})})}})}),define("app/dev/ops/user/getting-all-user-info-op",["core/ac-core","app/ac-app","core/utils/ipm-util","core/ops/op"],function(e,t,n){return t.GettingAllUserInfoOp=e.Op.extend({run:function(){var r=this.options,i=r.appApi.usersMeApi,s=e.opFactory,o=t.opFactory,u,a,f,l,c=window.DIL,h,p,d;return r.baseAicUrisModel.get("users")?(u=o.create("GettingUsersMeOp",r),a=s.create("GettingUsersMeCohortsOp",r),h=s.create("CheckingStorageQuotaOnStartupOp",_.extend({},r,{parentView:t.viewMgr.getContentPageView(r)})),p=s.create("GettingCommonLimitsOp",r),d=o.create("InitializingScLoggingOp",r),$.when(u.run().then(function(){d.run(),f=i.getUserIdentity(),n.setIpmParams(f,i.getSubscription()),l=f.user_id,c&&l&&c.getDil("adobe").api.aamIdSync({dpid:"813",dpuuid:l.split("@")[0]})}),a.run()).then(function(){return h.run(),e.Features.isFeatureEnabled("my_plan_ui")&&p.run(),i.restoreCommonPrefs()})):this._getResolvedPromise()}}),t.GettingAllUserInfoOp}),define("app/dev/ops/user/getting-users-me-limits-op",["core/ac-core","app/ac-app","aicx/ac-aicx","core/ops/op"],function(e,t,n){return t.GettingUsersMeLimitsOp=e.Op.extend({run:function(e,t){var r=this.options;return r.baseAicUrisModel.get("users")?n.opFactory.create("GettingUsersMeLimitsOp",r).run(e,t):this._getResolvedPromise()}}),t.GettingUsersMeLimitsOp}),define("app/dev/ops/user/getting-users-me-op",["core/ac-core","app/ac-app","aicx/ac-aicx","core/ops/op"],function(e,t,n){return t.GettingUsersMeOp=e.Op.extend({run:function(){var e=this.options;return e.baseAicUrisModel.get("users")?n.opFactory.create("GettingUsersMeOp",e).run():this._getResolvedPromise()}}),t.GettingUsersMeOp}),define("app/dev/ops/user/getting-users-me-prefs-op",["core/ac-core","app/ac-app","aicx/ac-aicx","core/ops/op"],function(e,t,n){return t.GettingUsersMePrefsOp=e.Op.extend({run:function(e,t){var r=this.options;return r.baseAicUrisModel.get("users")?n.opFactory.create("GettingUsersMePrefsOp",r).run(e,t):this._getResolvedPromise()}}),t.GettingUsersMePrefsOp}),define("app/dev/ops/user/restoring-common-prefs-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){return t.RestoringCommonPrefsOp=e.Op.extend({run:function(){var e=this.options,t=e.appApi.usersMeApi.getCommonUserPrefs(),n=t.quota;return n&&e.quotaDlgUiModel.set("running_out_shown",n.running_out_shown),this._getResolvedPromise()}}),t.RestoringCommonPrefsOp}),define("app/dev/ops/user/saving-common-prefs-op",["core/ac-core","app/ac-app","core/ops/op"],function(e,t){return t.SavingCommonPrefsOp=e.Op.extend({run:function(){var e=this.options,t=e.appApi,n,r={},i=this._getResolvedPromise();return t&&(n=t.usersMeApi.getUserIdentity().email),n?(r.quota={running_out_shown:e.quotaDlgUiModel.get("running_out_shown")},r.lastToolUsed=e.toolsUiModel.getSelectedId(),t.usersMeApi.setUserPrefs("common",r)):i}}),t.SavingCommonPrefsOp}),define("app/dev/ops/user/setting-users-me-prefs-op",["core/ac-core","app/ac-app","aicx/ac-aicx","core/ops/op"],function(e,t,n){return t.SettingUsersMePrefsOp=e.Op.extend({run:function(e,t){var r=this.options;return r.baseAicUrisModel.get("users")?n.opFactory.create("SettingUsersMePrefsOp",r).run(e,t):this._getResolvedPromise()}}),t.SettingUsersMePrefsOp}),define("app/dev/ops/op-factory",["core/ac-core","app/ac-app","app/ops/account-menu/loading-account-menu-op","app/ops/account-menu/selecting-account-menu-item-op","app/ops/acrobat/closing-in-acrobat-op","app/ops/acrobat/opening-in-acrobat-op","app/ops/acrobat/selecting-acrobat-filter-op","app/ops/app/rna-starting-app-op","app/ops/app/rna-running-app-op","app/ops/app/running-app-op","app/ops/app/starting-app-op","app/ops/app/starting-authenticated-app-op","app/ops/file-selection-dlg/loading-file-selection-dlg-home-views-op","app/ops/file-selection-dlg/selecting-file-selection-dlg-home-view-op","app/ops/file-selection-dlg/showing-file-selection-dlg-op","app/ops/file-selection-dlg/loading-file-selection-dlg-op","app/ops/whats-new-dlg/loading-whats-new-dlg-op","app/ops/getting/getting-all-base-uris-op","app/ops/getting/getting-storage-info-op","app/ops/listening/listening-for-ajax-events-op","app/ops/listening/listening-for-download-errors-op","app/ops/listening/listening-for-folder-notifications-op","app/ops/listening/listening-for-inactivity-op","app/ops/listening/listening-for-network-connectivity-op","app/ops/listening/listening-for-server-errors-op","app/ops/listening/listening-for-view-events-op","app/ops/listening/listening-for-window-events-op","app/ops/misc/handling-uncaught-exceptions-op","app/ops/misc/loading-custom-css-op","app/ops/misc/loading-deep-link-plugins-op","app/ops/misc/loading-framework-versions-op","app/ops/misc/loading-plugin-configs-op","app/ops/misc/loading-plugin-configs-versions-op","app/ops/misc/loading-rna-variant-info-op","app/ops/misc/loading-rna-version-info-op","app/ops/misc/loading-template-plugins-op","app/ops/misc/loading-typekit-op","app/ops/misc/navigating-to-about-dlg-op","app/ops/misc/overriding-jquery-ajax-op","app/ops/misc/redirecting-to-apollo-op","app/ops/misc/registering-app-apis-op","app/ops/misc/registering-plugins-ui-models-op","app/ops/misc/showing-about-dlg-op","app/ops/misc/showing-load-failures-dlg-op","app/ops/misc/showing-next-error-op","app/ops/misc/showing-support-home-op","app/ops/misc/showing-user-forum-op","app/ops/misc/starting-history-op","app/ops/misc/switching-language-op","app/ops/misc/toggling-account-menu-op","app/ops/misc/toggling-help-menu-op","app/ops/misc/validating-rna-version-info-op","app/ops/misc/apply-ui-theme-style-framework-op","app/ops/preferences/restoring-preferences-op","app/ops/preferences/saving-preferences-op","app/ops/rna/configuring-rna-op","app/ops/rna/initializing-rna-op","app/ops/rna/listening-for-dialog-alert-events-op","app/ops/rna/listening-for-notification-window-events-op","app/ops/rna/listening-for-rhp-window-events-op","app/ops/rna/listening-for-rna-events-op","app/ops/rna/listening-for-session-events-op","app/ops/routing/initializing-app-routes-op","app/ops/routing/initializing-sc-logging-op","app/ops/routing/rna-routing-at-content-page-op","app/ops/routing/routing-at-content-page-op","app/ops/session/handling-401-error-op","app/ops/session/signing-in-from-error-op","app/ops/session/signing-out-op","app/ops/settings-dlg/loading-settings-dlg-views-op","app/ops/settings-dlg/selecting-settings-dlg-plugin-op","app/ops/settings-dlg/showing-settings-dlg-op","app/ops/site-catalyst/get-framework-pages-op","app/ops/site-catalyst/register-page-names-op","app/ops/tools/loading-tools-op","app/ops/tools/selecting-tool-op","app/ops/user/getting-all-user-info-op","app/ops/user/getting-users-me-limits-op","app/ops/user/getting-users-me-op","app/ops/user/getting-users-me-prefs-op","app/ops/user/restoring-common-prefs-op","app/ops/user/saving-common-prefs-op","app/ops/user/setting-users-me-prefs-op"],function(e,t){t.OpFactory=e.Op.extend({create:function(e,n){var r=t[e];if(!!r)return new r(n);LOG(0,"AcApp.OpFactory.create: Unrecognized class: "+e)}})}),define("app/dev/ac-app-init",["app/ac-app","app/models/ui/ui-model-factory","app/views/view-mgr","app/ops/op-factory"],function(e){return _.extend(e,{uiModelFactory:new e.UiModelFactory,opFactory:new e.OpFactory,viewMgr:new e.ViewMgr,router:new Backbone.Router}),e}),define("app/dev/features",["underscore"],function(e){return e.extend(Ac.Features,{isFeatureEnabled:function(e){return this.getFeature(e)===!0},getFeature:function(e){var t=this.features[e];return t},setFeature:function(e,t){this.features[e]=t}}),Ac.Features}),define("app/dev/locale",["underscore"],function(e){var t={"ar-ae":"Arabic","ca-es":"Catalan","cs-cz":"Czech","da-dk":"Dansk","de-de":"Deutsch","en-ae":"Middle Eastern English for Arabic","en-gb":"English UK","en-us":"English US","en-il":"Middle Eastern English for Hebrew","es-es":"Español","eu-es":"Basque","fi-fi":"Suomi","fr-fr":"Français","fr-ma":"North African French","he-il":"Hebrew","hr-hr":"Croatian","hu-hu":"Hungarian","it-it":"Italiano","ja-jp":"日本語","ko-kr":"Korean","nb-no":"Norsk","nl-nl":"Nederlands","pl-pl":"Polish","pt-br":"Português","ro-ro":"Romanian",root:"English US","ru-ru":"Russian","sk-sk":"Slovak","sl-si":"Slovenian","sl-sl":"Unknown","sv-se":"Svenska","tr-tr":"Turkish","uk-ua":"Ukrainian","xx-xx":"Test Locale XX","zh-cn":"Chinese Simplified","zh-tw":"Chinese Traditional"};return e.extend(Ac.Locale,{getLocaleByCountry:function(t){var n=e.keys(this.localeMap),r;return t=t.toLowerCase(),r=e.find(n,function(e){return t===e.substr(3)}),r||"root"},getImsLocale:function(e){return e=e||this.getLocale(),e.substr(0,2)+"_"+e.substr(3).toUpperCase()},getIpmLocale:function(){return this.getImsLocale().replace("_","-")},getLanguageName:function(e){var n=t[e];return n||"English US"},getHelpLocale:function(){var e=this.getLocale();return e==="root"||e==="en-us"||e==="en-gb"?"en":e.substr(3)},getSiteCatalystLocale:function(){return this.getImsLocale().toLowerCase()}}),Ac.Locale}),define("app/dev/log",["underscore"],function(e){var t=function(n,r,i){var s=window.console,o,u,a=!0,f=!1,l,c=t.appApi,h,p;i&&(e.has(i,"logConsole")&&(a=!!i.logConsole),e.has(i,"logServer")&&(f=!!i.logServer),e.isString(i.plugin)&&(l=i.plugin),e.isString(i.env)&&(p=i.env)),Ac.Features.isFeatureEnabled("javascript_console_logging")||(a=!1),e.isNumber(n)&&(o=n,n=r,r=o||10),r=r||t.DEBUG,f&&c&&c.errorApi.sendLogEvent({message:n,severity:r}),!p&&l&&c&&(h=c.pluginsApi.getBaseUrl(l),h.indexOf("local")>=0?p="localdev":h.indexOf(".dev.")>=0?p="dev":h.indexOf(".test.")>=0?p="test":h.indexOf(".stage.")>=0?p="stage":p="prod");if(p==="stage"||p==="prod"){if(r